diff --git a/compose.yml b/compose.yml index dce8a5b..34f90e8 100644 --- a/compose.yml +++ b/compose.yml @@ -108,8 +108,7 @@ configs: template_driver: golang app_entrypoint: name: ${STACK_NAME}_app_entrypoint_${APP_ENTRYPOINT_VERSION} - file: entrypoint.sh.tmpl - template_driver: golang + file: entrypoint.sh secrets: db_password: diff --git a/entrypoint.sh.tmpl b/entrypoint.sh similarity index 90% rename from entrypoint.sh.tmpl rename to entrypoint.sh index 1fbc1e5..7a2567e 100644 --- a/entrypoint.sh.tmpl +++ b/entrypoint.sh @@ -8,10 +8,10 @@ set -e export PEERTUBE_DB_PASSWORD=$(cat "$PEERTUBE_DB_PASSWORD_FILE") unset PEERTUBE_DB_PASSWORD_FILE -{{ if eq (env "PEERTUBE_SMTP_ENABLED") "1" }} +if [ -z "$PEERTUBE_SMTP_ENABLED" ]; then export PEERTUBE_SMTP_PASSWORD=$(cat "$PEERTUBE_SMTP_PASSWORD_FILE") unset PEERTUBE_SMTP_PASSWORD_FILE -{{ end }} +fi # upstream entrypoint # https://github.com/Chocobozzz/PeerTube/blob/66f77f63437c6774acbd72584a9839a7636ea167/support/docker/production/entrypoint.sh