Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,3 +57,25 @@ jobs:
JIRA_USER_EMAIL: dummy@example.com
GITHUB_TOKEN: dummy
run: uv run pytest tests/unit/ -q

container-build:
name: Container Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Build production image
run: docker build --tag forge-ci:${{ github.sha }} .

- name: Verify application imports
run: >-
docker run --rm
--env JIRA_BASE_URL=https://example.atlassian.net
--env JIRA_API_TOKEN=dummy
--env JIRA_USER_EMAIL=dummy@example.com
--env GITHUB_TOKEN=dummy
forge-ci:${{ github.sha }}
python -c "import forge; from forge.main import app; assert app is not None"

- name: Verify Forge CLI entry point
run: docker run --rm forge-ci:${{ github.sha }} forge --help
8 changes: 4 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,11 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
git \
&& rm -rf /var/lib/apt/lists/*

# Install Python dependencies

# Install Python dependencies and copy application code
COPY pyproject.toml README.md ./
COPY src/ ./src/

RUN pip install --no-cache-dir build && \
pip wheel --no-cache-dir --wheel-dir /wheels -e .

Expand All @@ -30,9 +33,6 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
COPY --from=builder /wheels /wheels
RUN pip install --no-cache-dir /wheels/* && rm -rf /wheels

# Copy application code
COPY src/ ./src/

# Switch to non-root user
USER forge

Expand Down
Loading