diff --git a/web/src/docker/docker-entrypoint.d/100-execute-custom-scripts.sh b/web/src/docker/docker-entrypoint.d/100-execute-custom-scripts.sh new file mode 100755 index 0000000000..1503ed92a4 --- /dev/null +++ b/web/src/docker/docker-entrypoint.d/100-execute-custom-scripts.sh @@ -0,0 +1,11 @@ +#!/bin/bash + +# Executing custom scripts located in CUSTOM_SCRIPTS_DIRECTORY if environment variable is set +if [[ -z "${CUSTOM_SCRIPTS_DIRECTORY}" ]]; then + echo "[INFO] No CUSTOM_SCRIPTS_DIRECTORY env variable set" +else + echo "[INFO] CUSTOM_SCRIPTS_DIRECTORY env variable set to ${CUSTOM_SCRIPTS_DIRECTORY}" + # Regex is needed in jetty9 images, but not alpine's ones. + run-parts -v ${CUSTOM_SCRIPTS_DIRECTORY} --regex='.*' + echo "[INFO] End executing custom scripts" +fi diff --git a/web/src/docker/docker-entrypoint.sh b/web/src/docker/docker-entrypoint.sh index 4c54157358..a8ef218e94 100755 --- a/web/src/docker/docker-entrypoint.sh +++ b/web/src/docker/docker-entrypoint.sh @@ -4,7 +4,7 @@ DIR=/docker-entrypoint.d if [[ -d "$DIR" ]] then - /bin/run-parts --verbose "$DIR" + /bin/run-parts --verbose "$DIR" --regex='.*' fi exec "$@"