mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-26 10:26:15 -04:00
docker: support including plugins in custom builds.
This commit introduces the support for the ETHERPAD_PLUGINS build parameter, which contains a list of plugins to be installed while building the container. EXAMPLE: docker build --build-arg ETHERPAD_PLUGINS="ep_codepad ep_author_neat" --tag <YOUR_USERNAME>/etherpad . Resolves #3618.
This commit is contained in:
parent
b5ac653cbc
commit
4582f9daeb
2 changed files with 25 additions and 0 deletions
|
@ -13,6 +13,14 @@ LABEL maintainer="Etherpad team, https://github.com/ether/etherpad-lite"
|
|||
# If not given, build the latest development version.
|
||||
ARG ETHERPAD_VERSION=develop
|
||||
|
||||
# plugins to install while building the container. By default no plugins are
|
||||
# installed.
|
||||
# If given a value, it has to be a space-separated, quoted list of plugin names.
|
||||
#
|
||||
# EXAMPLE:
|
||||
# ETHERPAD_PLUGINS="ep_codepad ep_author_neat"
|
||||
ARG ETHERPAD_PLUGINS=
|
||||
|
||||
# Set the following to production to avoid installing devDeps
|
||||
# this can be done with build args (and is mandatory to build ARM version)
|
||||
ARG NODE_ENV=development
|
||||
|
@ -38,6 +46,12 @@ WORKDIR /opt/etherpad-lite
|
|||
# install node dependencies for Etherpad
|
||||
RUN bin/installDeps.sh
|
||||
|
||||
# Install the plugins, if ETHERPAD_PLUGINS is not empty.
|
||||
#
|
||||
# Bash trick: in the for loop ${ETHERPAD_PLUGINS} is NOT quoted, in order to be
|
||||
# able to split at spaces.
|
||||
RUN for PLUGIN_NAME in ${ETHERPAD_PLUGINS}; do npm install "${PLUGIN_NAME}"; done
|
||||
|
||||
# Copy the custom configuration file, if present. The configuration file has to
|
||||
# be manually put inside the same directory containing the Dockerfile (we cannot
|
||||
# directly point to "../settings.json" for Docker's security restrictions).
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue