Skip to content

ci: build image + validate nginx on PRs; fix duplicate proxy_read_timeout - #33

Merged
ronibhakta1 merged 3 commits into
readium:mainfrom
ronibhakta1:ci/docker-build-check
Oct 8, 2026
Merged

ronibhakta1 merged 3 commits into
readium:mainfrom
ronibhakta1:ci/docker-build-check

Conversation

@ronibhakta1

@ronibhakta1 ronibhakta1 commented Oct 8, 2026 •

Copy link
Copy Markdown
Member

Problem

`ci.yml` runs lint/format/mypy/pytest on PRs, but the Docker image is only built in `deploy.yml` after merge to `main`. A broken Dockerfile, `uv.lock` or missing file would only surface during deployment.

Change

New `build` job in `ci.yml`, `needs: test` (skipped if tests fail):

  • `docker compose config -q` validates the compose file.
  • Builds the same Dockerfile `deploy.yml` pushes, with `push: false` and GHA layer cache.

Nothing is pushed or deployed from PRs. To make the check blocking, mark `build` as a required status check in branch protection.

Not covered

Runtime behaviour of the image (model downloads, ffmpeg at runtime).

Added: nginx config check + the fix it caught

Renders nginx/templates and runs nginx -t in nginx:alpine (throwaway cert). It failed on main with "proxy_read_timeout" directive is duplicate — the cause of the prod nginx crash — so this PR also carries the fix (formerly #34): proxy_read_timeout moves from the shared snippet to per-location (120s in /, 300s in /synthesize; effective values unchanged).

@ronibhakta1
ronibhakta1 force-pushed the ci/docker-build-check branch from 3f243b7 to 35c38b5 Compare October 8, 2026 14:10
@ronibhakta1
ronibhakta1 force-pushed the ci/docker-build-check branch from 35c38b5 to 1fe619e Compare October 8, 2026 14:19
@ronibhakta1 ronibhakta1 changed the title ci: build docker image on PRs after tests pass ci: build image + validate nginx on PRs; fix duplicate proxy_read_timeout Oct 8, 2026
@ronibhakta1
ronibhakta1 merged commit 9e8558c into readium:main Oct 8, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant