mirror of
https://gitlab.com/psono/psono-admin-client
synced 2025-04-19 03:22:17 +03:00
added option to overwrite the config.json with environment variables
Signed-off-by: Sascha Pfeiffer <sascha.pfeiffer@psono.com>
This commit is contained in:
parent
8d9f2cb7e9
commit
787bb13bdc
@ -7,8 +7,11 @@ RUN apk upgrade --no-cache \
|
||||
|
||||
COPY ./configs/nginx.conf /etc/nginx/nginx.conf
|
||||
COPY ./configs/default.conf /etc/nginx/conf.d/default.conf
|
||||
COPY ./configs/cmd.sh /root/cmd.sh
|
||||
COPY ./build /usr/share/nginx/html/portal
|
||||
COPY ./configs/redirect.html /usr/share/nginx/html/index.html
|
||||
|
||||
HEALTHCHECK --interval=30s --timeout=3s \
|
||||
CMD curl -f http://localhost/ || exit 1
|
||||
|
||||
CMD ["/bin/sh", "/root/cmd.sh"]
|
||||
|
6
configs/cmd.sh
Normal file
6
configs/cmd.sh
Normal file
@ -0,0 +1,6 @@
|
||||
if [ ! -z "$PSONO_PORTAL_CONFIG_JSON" ]
|
||||
then
|
||||
echo "$PSONO_PORTAL_CONFIG_JSON" > /usr/share/nginx/html/portal/config.json
|
||||
fi
|
||||
|
||||
nginx -g "daemon off;"
|
Loading…
x
Reference in New Issue
Block a user