Repository navigation
fix(ci): deploy web after API with run-number versions - #1087
Conversation
Run the web workflow only after integration tests and a successful API deployment. Use the API workflow run number for API image tags, binary versions, and the frontend client version. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: a0fd7292-f3aa-4919-929f-d73c2ac0f0c2
Up to standards ✅🟢 Issues
|
| Metric | Results |
|---|---|
| Complexity | 0 |
| Duplication | 0 |
NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.
[Medium impact] This PR appears safe to merge. SummaryThis PR makes production frontend deployment wait for a successful API deployment.
Diagram%%{init: {'theme': 'neutral'}}%%
flowchart TD
Push[Push to main] --> Tests[Integration tests]
Tests --> API[Build and deploy API]
API --> Validate[Validate frontend]
Validate --> Build[Build frontend]
Build --> Cloudflare[Deploy to Cloudflare]
Cloudflare --> Firebase[Deploy to Firebase]
PR[Pull request] --> PRValidate[Standalone frontend checks]
Reviews (1) · Last reviewed commit: "fix(ci): deploy web after API with run-n..." · Reviewed by Greptile |
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues were identified for the coordinated API and frontend deployment changes.
No open issues 🎉
What changed in this PR
This PR coordinates httpSMS production deployments so frontend validation and deployment follow a successful API deployment, with both components using the API workflow’s run number as their version.
Changes:
- Call the reusable web workflow after API deployment while preserving standalone frontend validation on pull requests.
- Pass the run number through Cloud Build for API image tags and the compiled binary version.
- Use the inherited run number for the frontend client version, retaining the local
devfallback.
| File | Description |
|---|---|
web/nuxt.config.ts |
Uses GITHUB_RUN_NUMBER for the client version. |
api/Dockerfile |
Embeds the VERSION build argument in the API binary. |
api/cloudbuild.yaml |
Uses _VERSION for image tags, builds, and deployment. |
.github/workflows/web.yml |
Enables reusable invocation, retains PR validation, and removes SHA injection. |
.github/workflows/api.yml |
Supplies the run-number version and calls the web workflow after API deployment. |
Review effort: Balanced
Summary
github.run_numberfor API image tags, the API binary version, and the frontend client version. The reusable workflow inherits the caller's run number, keeping both components on the same increasing version; retries retain their original version.Verification
devfallback.Note
The existing lockfile violates pnpm's 24-hour minimum release-age policy, blocking the pnpm wrapper and Husky hook. Targeted checks were run directly with installed tools; Husky was skipped for this commit with explicit approval. Dependency files and supply-chain policy were not changed. Production deployment will occur after merge.