Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

166
Views
version `GLIBC_2.25' not found when trying to use argon2 hash function javascript/typescript

I am trying to use the hash function from the argon2 JavaScript package, but I am getting the following error:

Error: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.25' not found (required by /app/node_modules/argon2/lib/binding/napi-v3/argon2.node)
     at Object.Module._extensions..node (internal/modules/cjs/loader.js:1144:18)
     at Module.load (internal/modules/cjs/loader.js:950:32)
     at Function.Module._load (internal/modules/cjs/loader.js:790:12)
     at Module.require (internal/modules/cjs/loader.js:974:19)
     at require (internal/modules/cjs/helpers.js:93:18)
     at Object.<anonymous> (/app/node_modules/argon2/argon2.js:9:56)
     at Module._compile (internal/modules/cjs/loader.js:1085:14)
     at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10)
     at Module.load (internal/modules/cjs/loader.js:950:32)
     at Function.Module._load (internal/modules/cjs/loader.js:790:12) {
   code: 'ERR_DLOPEN_FAILED'
 }
 [nodemon] app crashed - waiting for file changes before starting...

Here is the my code that is erroring out:

import { hash } from "argon2";
(async () {
  const hashedPassword = await hash(password);
})();

I did find this discussion on askubuntu.com, but the steps illustrated there don't really apply to me. The error might be coming from the fact that I am using docker...

Here is the dockerfile for my server (where the erroring code lives):

FROM node:14

WORKDIR /app

COPY package*.json .

RUN npm i

COPY . .

EXPOSE 80

CMD ["npm", "run", "dev"]

Here is the .dockerignore file:

/node_modules
/Dockerfile

And here is my docker-compose.yaml file (the 'server' service is the one we are concerned with):

version: "3.8"
services:
  db:
    image: mysql
    ports:
      - 3308:3306
    environment:
       ***
  redis:
    image: redis
    command: "redis-server --requirepass secret"
  server:
   build: ./server
   ports: 
    - "4000:80"
   volumes:
     - ./server:/app
     - /app/node_modules
     - /app/dist
   environment:
       ***

I haven't displayed my environment variables for obvious reasons.

Thank you for any help and feedback.

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!