From c4fd118136031d0be5229519a61fdf468979383b Mon Sep 17 00:00:00 2001 From: Tyler Dane Date: Wed, 14 Oct 2026 16:40:43 -0600 Subject: [PATCH 1/2] fix(deploy): build web image with its own deploy config, not boot-size placeholders #4466 made Dockerfile.web run run-boot-size-check.sh, which forces COMPASS_CONFIG_FILE=.github/perf/compass.boot-size.yaml. Staging-cloud v1.3.164 shipped a bundle pointing at https://api.compasscalendar.com/api with a placeholder PostHog key, so calendars and events failed to load. --- .github/docker/Dockerfile.web | 8 +++++--- self-host/docker-compose.test.ts | 7 +++++-- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/.github/docker/Dockerfile.web b/.github/docker/Dockerfile.web index d2a25ab57..6f7a538f2 100644 --- a/.github/docker/Dockerfile.web +++ b/.github/docker/Dockerfile.web @@ -63,9 +63,11 @@ RUN if [ -n "$GOOGLE_PLACES_API_KEY" ]; then \ >> compass.yaml; \ fi -# Measure boot gzip for logs; deploy must not fail on absolute bundle size. -ENV COMPASS_BOOT_SIZE_ENFORCE=0 -RUN .github/perf/run-boot-size-check.sh +# Build with the compass.yaml written above (real API URL, PostHog, OAuth). +# Never run .github/perf/run-boot-size-check.sh here: it swaps in the +# placeholder compass.boot-size.yaml, which pointed staging at the wrong API. +# Boot size is gated per PR in boot-bundle.yml, not at deploy. +RUN cd apps/calendar-web && bun run build.ts FROM oven/bun:1.3.14-slim AS runtime diff --git a/self-host/docker-compose.test.ts b/self-host/docker-compose.test.ts index 267c77703..7b6cb056f 100644 --- a/self-host/docker-compose.test.ts +++ b/self-host/docker-compose.test.ts @@ -705,8 +705,11 @@ describe("staging deploy workflow", () => { expect(bootConfig).toContain("posthog:"); expect(dockerfile).toContain("nodeEnv: ${NODE_ENV}"); expect(dockerfile).toContain("'posthog:'"); - expect(dockerfile).toContain(".github/perf/run-boot-size-check.sh"); - expect(dockerfile).toContain("COMPASS_BOOT_SIZE_ENFORCE=0"); + // The image must build with its own deploy compass.yaml. The boot-size + // script swaps in placeholder config (fake API URL and PostHog key). + expect(dockerfile).toContain("RUN cd apps/calendar-web && bun run build.ts"); + expect(dockerfile).not.toContain("RUN .github/perf/run-boot-size-check.sh"); + expect(dockerfile).not.toContain("COMPASS_CONFIG_FILE"); }); it("builds cloud deploy web images from a GitHub-only Dockerfile with PostHog config", () => { From 186f2080bbfa7e820f2ea84477cd4d84ed9a8d7b Mon Sep 17 00:00:00 2001 From: Tyler Dane Date: Wed, 14 Oct 2026 16:53:58 -0600 Subject: [PATCH 2/2] style: biome format --- self-host/docker-compose.test.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/self-host/docker-compose.test.ts b/self-host/docker-compose.test.ts index 7b6cb056f..fb99be57f 100644 --- a/self-host/docker-compose.test.ts +++ b/self-host/docker-compose.test.ts @@ -707,7 +707,9 @@ describe("staging deploy workflow", () => { expect(dockerfile).toContain("'posthog:'"); // The image must build with its own deploy compass.yaml. The boot-size // script swaps in placeholder config (fake API URL and PostHog key). - expect(dockerfile).toContain("RUN cd apps/calendar-web && bun run build.ts"); + expect(dockerfile).toContain( + "RUN cd apps/calendar-web && bun run build.ts", + ); expect(dockerfile).not.toContain("RUN .github/perf/run-boot-size-check.sh"); expect(dockerfile).not.toContain("COMPASS_CONFIG_FILE"); });