Commit Graph

1 Commits

Author SHA1 Message Date
Michael Czechowski
edd3dee3d9 feat: bake default white-label nginx.conf into the image
All checks were successful
Build and publish / build (pull_request) Successful in 19s
The image used to ship just nginx + an entrypoint, with no routing
config — adapters had to mount their own nginx.conf via compose
`configs:` for anything to work. This broke the standalone
libreshop/demo preview (`curl /admin` returned 404).

Add a default nginx.conf.template that routes the standard libreshop
surface (`/admin`, `/uploads`, `/api`, `/`, ...) to
`${NGINX_UPSTREAM_CMS:-cms:5555}` / `${NGINX_UPSTREAM_SHOP:-shop:9999}`,
plus health and forwarded-headers handling. The entrypoint runs
envsubst at startup, then nginx.

Adapter override path is preserved: if compose `configs:` already
replaced /etc/nginx/nginx.conf with a non-stock file (detected via
the absence of the upstream nginx `worker_processes  auto;` line),
the entrypoint leaves it untouched.

Closes #1.
2026-04-29 19:20:43 +02:00