Qovery + Puppeteer

Hi team!

Trying to deploy aan app that has puppeteer as dependancy. (nodejs app)
It works good locally, when when I use the feature on production I get

error while loading shared libraries: libdrm.so.2: cannot open shared object file: No such file or directory

And my docker file does have the libdrm dependency


FROM node:18.16.0
WORKDIR /app
COPY . .

ENV NODE_VERSION 18.16.0

RUN apt-get update && apt-get install -y \
    libx11-xcb1 libxcomposite1 libxi6 libxext6 libxtst6 \
    libnss3 libcups2 libxss1 libxrandr2 libasound2 libpangocairo-1.0-0 \
    libatk1.0-0 libatk-bridge2.0-0 libgtk-3-0 libdrm2 \
    && rm -rf /var/lib/apt/lists/*

RUN yarn
RUN yarn build

ENTRYPOINT ["./docker/entrypoint.sh"]

EXPOSE 3000
CMD ["npm", "run", "start"]

Do you know what could be the issue ? Thank you!

Hey @CBaptiste,

Can you try to add the following dependencies as well?

libdrm2
libice6
libsm6

Source libdrm.so.2: cannot open shared object file · Issue #12 · xorilog/docker-telegram · GitHub

Cheers

Hey hey :wave:

maybe this could help as well https://github.com/puppeteer/puppeteer/tree/main/docker

Be careful to check the puppeteer version, the docker image had some changes over the last years

1 Like