ci: add GitHub Actions for lint/test, PR image build, and GHCR publish - #155
Merged
Conversation
14 tasks
Add ci.yml (ruff + pytest gates and a no-push Docker build on PRs to develop/main and pushes to main) and release.yml (build and push the image to ghcr.io/jaherhum/crowdroom with latest + sha tags on push to main). Also add the missing docstring on ConnectionType so ruff check passes, unblocking the lint gate. Closes #151 Closes #145
jaherhum
force-pushed
the
feature/ci-actions
branch
from
June 21, 2026 22:05
21121ae to
608305d
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Add GitHub Actions workflows to gate lint/tests, validate the Docker image build on PRs, and publish the image to GHCR on merge to
main. Also fixes a pre-existingD101lint error that would otherwise make the lint gate red on its first run.Related issue
closes #151
closes #145
Type of change
Changes
.github/workflows/ci.yml(new): runs on PRs todevelop/mainand pushes tomain.lint-test:uv sync --dev→uv run ruff check→uv run pytest. Tests run with dummySECRET_KEY/ENCRYPTION_KEYenv (settings are instantiated at import). No Postgres service — PG tests are@skip_pgand the rest use mocks.docker-build: builds the repo-root multi-stageDockerfilewithpush: falseto catch Dockerfile regressions on PRs..github/workflows/release.yml(new): on push tomain, logs in to GHCR withGITHUB_TOKEN, then builds and pushesghcr.io/jaherhum/crowdroomtaggedlatest+sha-<commit>.backend/db/models/enum.py: add the missing docstring onConnectionType(fixesD101).Testing
uv run ruff checkpasses.uv run pytestwith dummy env and no.env: 390 passed, 9 skipped. YAML of both workflows validated.Checklist
.envand secrets are not includedAdditional notes
GHCR auth uses the built-in
GITHUB_TOKENwithpackages: write— no extra secrets required. The published image reuses the compose wiring from #150/#154. The dummySECRET_KEY/ENCRYPTION_KEYvalues inci.ymlare CI-only throwaways, not real secrets.