Consolidate Docker publishing into build-and-test workflow#88
Conversation
Make the tested Docker pipeline own the image the web/k8s deployment pulls (ghcr.io/openms/flashapp:latest) so a release ships a validated image, built after the Windows installer it bundles. - build-windows-executable-app.yaml: add a `publish-web-image` job that, on a published release, calls build-and-test.yml (reusable workflow) after the Windows installer is uploaded as a release asset. This preserves the ordering the Docker build relies on (it bundles the installer via `gh release download`). - build-and-test.yml: add a `workflow_call` trigger and drop the racy `tags: ['v*']` push trigger; enable the `:latest` (and SIF `:latest`) tags on release as well as develop; gate the multi-arch manifest + `:latest` promotion behind the apptainer/nginx/traefik tests by adding them to create-manifest's `needs`. - Dockerfile/Dockerfile.arm: add a RELEASE_TAG arg to pin the bundled installer to the release being published (falls back to latest release for develop/manual builds). - Remove publish-docker-images.yml, the untested release-publish workflow now superseded by build-and-test.yml (whose workflow_dispatch remains the manual rebuild fallback). https://claude.ai/code/session_011vfx32E4R7HTs19TtHZps9
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (5)
💤 Files with no reviewable changes (1)
📝 WalkthroughWalkthroughThe PR consolidates Docker image publishing from a dedicated ChangesRelease-pinned Docker publishing consolidation
Sequence DiagramsequenceDiagram
participant Release as GitHub Release
participant WindowsWorkflow as Windows Executable<br/>Workflow
participant BuildTestWorkflow as Build & Test<br/>Workflow (reusable)
participant DockerBuild as Docker Build<br/>(AMD64/ARM64)
participant Registry as GHCR Registry
participant Integration as Integration Tests<br/>(apptainer/nginx/traefik)
Release->>WindowsWorkflow: trigger on release event
WindowsWorkflow->>WindowsWorkflow: build-executable
WindowsWorkflow->>BuildTestWorkflow: invoke via workflow_call
BuildTestWorkflow->>DockerBuild: build-amd64 (with RELEASE_TAG)
BuildTestWorkflow->>DockerBuild: build-arm64 (with RELEASE_TAG)
DockerBuild->>Registry: push amd64/arm64 images<br/>tagged as "latest"
BuildTestWorkflow->>Integration: run test-apptainer,<br/>test-nginx, test-traefik
Integration-->>BuildTestWorkflow: pass
BuildTestWorkflow->>Registry: create-manifest<br/>(multi-arch, "latest" tag)
Possibly Related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
Removes the standalone
publish-docker-images.ymlworkflow and consolidates Docker image building and publishing into thebuild-and-test.ymlworkflow. This simplifies the CI/CD pipeline by eliminating a separate workflow file and ensuring Docker images are only published after passing integration tests (apptainer, nginx, traefik).Key Changes
.github/workflows/publish-docker-images.yml— standalone workflow that built and published Docker images to GHCR.github/workflows/build-and-test.yml:tags: ['v*']toworkflow_callto allow invocation from other workflowslatest-amd64andlatest-arm64tag conditions to enable on bothreleaseevents and develop branch pushesRELEASE_TAGbuild argument (passed on release events) to pin Docker image builds to the specific release being publishedcreate-manifestjob to depend on integration test jobs (test-apptainer,test-nginx,test-traefik), ensuring multi-arch manifests are only created after tests pass.github/workflows/build-windows-executable-app.yaml:publish-web-imagejob that triggersbuild-and-test.ymlas a reusable workflow on release eventsDockerfileandDockerfile.arm:RELEASE_TAGbuild argumentImplementation Details
The new flow for releases:
build-windows-executable-app.yamlbuilds and uploads Windows installerpublish-web-imagejob callsbuild-and-test.ymlwithRELEASE_TAGsetbuild-and-test.ymlbuilds Docker images with the matching release tag, runs integration testsThis ensures the Docker images bundled with a release contain the exact matching Windows installer, and that all images pass integration tests before being promoted to
:latesttags.https://claude.ai/code/session_011vfx32E4R7HTs19TtHZps9
Summary by CodeRabbit