Add docker bake environment
with support for building an Element Web docker image with build & runtime module loader with support for building docker images with a module pre-baked in
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
ARG ELEMENT_VERSION=latest
|
||||
FROM vectorim/element-web:${ELEMENT_VERSION}
|
||||
ARG ELEMENT_WEB_MODULES=""
|
||||
|
||||
# Override default nginx config. Templates in `/etc/nginx/templates` are passed
|
||||
# through `envsubst` by the nginx docker image entry point.
|
||||
COPY /docker/nginx-templates/* /etc/nginx/templates/
|
||||
COPY /docker/docker-entrypoint.d/* /docker-entrypoint.d/
|
||||
|
||||
# Create directories before we gain privileges
|
||||
RUN mkdir -p /tmp/element-web-config /tmp/element-web-modules
|
||||
|
||||
# Escalate privileges to install jq and moreutils and run the fetch modules script
|
||||
USER root
|
||||
RUN apk add jq moreutils
|
||||
RUN ELEMENT_WEB_MODULES=${ELEMENT_WEB_MODULES} /docker-entrypoint.d/17-fetch-element-modules.sh
|
||||
|
||||
# Drop privileges back to nginx
|
||||
USER nginx
|
||||
Reference in New Issue
Block a user