Skip to content

ci: Add GitHub Actions CI/CD workflows (closes #8) - #10

Merged
neuromechanist merged 4 commits into
mainfrom
feature/issue-8-github-actions-cicd
Jan 8, 2026
Merged

neuromechanist merged 4 commits into
mainfrom
feature/issue-8-github-actions-cicd

Conversation

@neuromechanist

Copy link
Copy Markdown
Member

Summary

Set up GitHub Actions for automated testing and deployment, following HEDit deployment patterns.

Workflows Added/Updated:

  • test.yml (new): Comprehensive test workflow

    • Lint job: ruff check and format
    • Unit tests: Python 3.11 and 3.12, excludes integration/llm markers
    • Integration tests: runs on push/dispatch with OPENROUTER_API_KEY secret
    • Codecov integration for coverage reporting
    • Summary job to aggregate results
  • docker-build.yml (new): Docker build and push

    • Build and smoke test on all pushes/PRs
    • Push to GHCR on main branch and tags
    • Polling health check (not hardcoded sleep)
  • deploy/Dockerfile (new): Production Docker image

    • Compatible with HEDit deployment patterns
    • Uses python:3.12-slim-bullseye with curl
    • Port 38428 (distinct from HEDit's 38427)
    • Health check endpoint
  • publish.yml (existing): Already configured for PyPI publishing

Test plan

  • YAML syntax validated
  • Unit tests pass (339 passed)
  • PR review completed, all critical and important issues addressed
  • Dockerfile aligned with HEDit patterns for compatibility

Closes #8

…tests

- Lint job: ruff check and format
- Unit tests: runs on Python 3.11 and 3.12, excludes integration/llm markers
- Integration tests: runs on push/dispatch with OPENROUTER_API_KEY secret
- Codecov integration for coverage reporting
- Replaces simpler tests.yml
- docker-build.yml: Build, test, and push to GHCR
- deploy/Dockerfile: Multi-stage build with uv for fast installs
- Smoke tests container before pushing
- Pushes to GHCR on main branch and tags
Critical fixes:
- Dockerfile: Add src/version.py copy (required by hatchling)
- Dockerfile: Use Python for healthcheck (no curl in slim image)

Important fixes:
- Dockerfile: Add non-root user for security
- docker-build.yml: Use polling loop instead of hardcoded sleep
- test.yml: Add warning annotation when integration tests skipped
- test.yml: Clarify that integration tests skip on PRs
- Use python:3.12-slim-bullseye (consistent with HEDit)
- Install curl for healthcheck (consistent with HEDit)
- Same environment variables and uv approach
- Port 38428 (distinct from HEDit's 38427)
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.

Phase 4: GitHub Actions CI/CD

1 participant