mirror of
https://github.com/casjaysdevdocker/super-productivity
synced 2026-09-05 06:54:24 -04:00
🐛 Fix container init so nginx starts reliably 🐛
Four bugs prevented nginx from starting in the super-productivity container. All four are fixed; tested end-to-end: HTTP 200 on /, /health returns "healthy", and sync-config-default-override.json is written correctly from SUPERSYNC_BASE_URL env vars. - Dockerfile: remove /etc/postfix and /etc/ssmtp in the pkmgr RUN step so ssmtp binary cannot resolve config dirs that were never installed - rootfs/usr/local/bin/entrypoint.sh: make __setup_mta non-fatal with || true; image has ssmtp binary but no config dirs — MTA is optional - rootfs/usr/local/etc/docker/functions/entrypoint.sh: fix __setup_mta guard (bare return → return 0) so it does not exit caller with code 1; gate all verbose debug echoes behind DEBUGGER=on so they do not slow down __fix_permissions / __setup_directories with unnecessary tee pipes - rootfs/usr/local/etc/docker/init.d/zz-nginx.sh: guard EXEC_PRE_SCRIPT type-P lookup behind [ -n ] so type -P '' cannot fire __trap_err_handler; create nginx.local.sh with touch inside __create_service_env and remove its __file_exists_with_content check from exitCode so the function returns 0 and zz-nginx.sh proceeds to __run_start_script Dockerfile rootfs/usr/local/bin/entrypoint.sh rootfs/usr/local/etc/docker/functions/entrypoint.sh rootfs/usr/local/etc/docker/init.d/zz-nginx.sh
This commit is contained in:
@@ -422,8 +422,8 @@ if [ "$ENTRYPOINT_FIRST_RUN" != "no" ] || [ "$CONFIG_DIR_INITIALIZED" = "no" ] |
|
||||
echo "Initialized on: $INIT_DATE" >"$ENTRYPOINT_INIT_FILE" 2>/dev/null || true
|
||||
fi
|
||||
# - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
# setup the smtp server
|
||||
__setup_mta
|
||||
# setup the smtp server — non-fatal; image may lack MTA config dirs
|
||||
__setup_mta || true
|
||||
# - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||
ENTRYPOINT_FIRST_RUN="no"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user