Docker: Update to the latest LTS image

The Node.js 14 slim image has quite a few vulnerabilities, and I have
tested the latest slim image. It works just fine.

When installing plugins, `--legacy-peer-deps` is passed to npm because
npm v7 (which comes with Node.js v16, the current LTS) changed how
peer deps are handled. The new behavior is incompatible with how
plugins have historically been installed.
pull/5308/head
Tommy 2021-11-08 11:40:34 -05:00 committed by Richard Hansen
parent a02e45499d
commit 48080411fc
1 changed files with 2 additions and 2 deletions

View File

@ -4,7 +4,7 @@
#
# Author: muxator
FROM node:14-buster-slim
FROM node:lts-slim
LABEL maintainer="Etherpad team, https://github.com/ether/etherpad-lite"
# plugins to install while building the container. By default no plugins are
@ -85,7 +85,7 @@ COPY --chown=etherpad:etherpad ./ ./
# seems to confuse tools such as `npm outdated`, `npm update`, and some ESLint
# rules.
RUN { [ -z "${ETHERPAD_PLUGINS}" ] || \
npm install --no-save ${ETHERPAD_PLUGINS}; } && \
npm install --no-save --legacy-peer-deps ${ETHERPAD_PLUGINS}; } && \
src/bin/installDeps.sh && \
rm -rf ~/.npm