Repository navigation
fix(docker): align migrate to v4.19.1 and cross-compile builder natively - #1240
Conversation
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
Warning Review limit reachedYou’ve reached a temporary PR review limit under our Fair Usage Limits Policy. Next review available in: 54 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
@coderabbitai review |
✅ Action performedReview finished.
|
Adversarial-review passRan the playbook against the brief's risk surfaces: migrate v4.17 → v4.19.1 schema compat (with the In-scope fix pushed (9152344)
Confirmed clean
Out-of-scope follow-up filed
Re-pinging CR. |
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
@coderabbitai review |
✅ Action performedReview finished.
|
The runtime image baked golang-migrate v4.17.0 while every CI/ops job (ci.yml, database-migration.yml) installs v4.19.1, so migrations validated in CI could behave differently when applied by the in-image binary via DB_AUTO_MIGRATE. Bump the Dockerfile download to v4.19.1 with the official release SHA256 checksums (verified independently by downloading both tarballs and recomputing the digests). Also add --platform=$BUILDPLATFORM to the Go builder stage, matching the existing frontend-builder stage: the build is a pure CGO_ENABLED=0 cross-compile driven by GOOS/GOARCH, so running the Go toolchain under QEMU for cross-arch builds only wastes CI minutes. TARGETARCH/TARGETOS still resolve to the output platform, so the migrate download (copied, never executed, in the builder) keeps fetching the target-arch binary. Closes #1205
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
Merge-prep: rebased onto origin/main (27fdb06). Gates: Dockerfile structural check exit 0 (--platform=$BUILDPLATFORM present, migrate v4.19.1, updated SHA256 hashes for arm64 and amd64), |
|
✅ Action performedReview finished.
|
|
Merged on the substantive CI signal (all Lint/Unit/Integration/Security/Build/E2E/Validate-Terraform green; only the non-blocking tflint pre-commit flake red) closes #1205. |
Problem (INF-11, P3)
.github/workflows/ci.yml,.github/workflows/database-migration.yml) installs v4.19.1. A migration validated by v4.19.1 in CI could behave differently when applied by the in-image v4.17.0 binary viaDB_AUTO_MIGRATE.FROM --platform=$BUILDPLATFORM, so cross-arch builds ran the Go toolchain under QEMU despite being a pureCGO_ENABLED=0cross-compile (the frontend stage already used it).Fix
Dockerfileonly:migrate.linux-{arm64,amd64}.tar.gztarballs and recomputed the digests; they match the releasesha256sum.txt.--platform=$BUILDPLATFORMto the Go builderFROM, mirroring the frontend-builder stage.TARGETARCH/TARGETOSstill resolve to the output platform, so the migrate download (copied, never executed, in the builder) keeps fetching the target-arch binary and the Go build still cross-compiles viaGOOS/GOARCH.No changes to the workflows or
Dockerfile.test(out of scope / owned elsewhere).Test evidence
docker buildx build --platform linux/arm64 --target builder .succeeds:migrate.tar.gz: OK(v4.19.1 arm64 checksum verified in-build),Building for linux/arm64Go build completes, exit 0.docker buildx build --platform linux/amd64 --target builder .succeeds (exercises the amd64 checksum branch and the native cross-compile path), exit 0.Closes #1205