Dockerfile 949 B

12345678910111213141516171819202122232425262728293031
  1. # This file was auto-generated, do not edit it directly.
  2. # Instead run bin/update_build_scripts from
  3. # https://github.com/overleaf/internal/
  4. FROM node:20.18.0 AS base
  5. WORKDIR /overleaf/services/spelling
  6. COPY services/spelling/install_deps.sh /overleaf/services/spelling/
  7. RUN chmod 0755 ./install_deps.sh && ./install_deps.sh
  8. # Google Cloud Storage needs a writable $HOME/.config for resumable uploads
  9. # (see https://googleapis.dev/nodejs/storage/latest/File.html#createWriteStream)
  10. RUN mkdir /home/node/.config && chown node:node /home/node/.config
  11. FROM base AS app
  12. COPY package.json package-lock.json /overleaf/
  13. COPY services/spelling/package.json /overleaf/services/spelling/
  14. COPY libraries/ /overleaf/libraries/
  15. COPY patches/ /overleaf/patches/
  16. RUN cd /overleaf && npm ci --quiet
  17. COPY services/spelling/ /overleaf/services/spelling/
  18. FROM app
  19. RUN mkdir -p cache \
  20. && chown node:node cache
  21. USER node
  22. CMD ["node", "--expose-gc", "app.js"]