fix: add Hub and Cube env vars to Docker build secrets#7950
Conversation
HUB_API_URL is required by the Zod env validation at build time but was not provided as a Docker secret, causing the release build to fail. Adds HUB_API_URL with a dummy fallback (http://localhost:4000) to the build pipeline, following the same pattern as DATABASE_URL/REDIS_URL. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
WalkthroughThis pull request adds a new 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 inconclusive)
✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. 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 |
Makes Cube env vars mandatory in env.ts (per PR #7913) and adds them as Docker build secrets with fallback values, following the same pattern as DATABASE_URL, REDIS_URL, and HUB_API_URL. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Hub is mandatory in v5, so HUB_API_KEY should fail fast at startup if not configured. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Tests now expect validation failures when CUBEJS_API_URL, CUBEJS_API_SECRET, or HUB_API_KEY are missing, and all test env helpers provide HUB_API_KEY. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|



Summary
HUB_API_URL,HUB_API_KEY,CUBEJS_API_URL, andCUBEJS_API_SECRETrequired inenv.ts— Hub and Cube are mandatory in v55.0.0-beta.1Docker release build failureChanges
apps/web/lib/env.ts—HUB_API_KEY: z.string().trim().min(1),CUBEJS_API_SECRET: z.string().trim().min(1),CUBEJS_API_URL: z.url()(HUB_API_URL was already required)read-secrets.sh— reads Hub and Cube secrets with fallbacksDockerfile— mountshub_api_url,hub_api_key,cubejs_api_url,cubejs_api_secretsecretsbuild-and-push-docker/action.yml— passes new secrets and env vars to Depot buildsecrets.*Required repo secrets
DUMMY_HUB_API_URLhttp://localhost:4000DUMMY_HUB_API_KEYDUMMY_CUBEJS_API_URLhttp://localhost:4000DUMMY_CUBEJS_API_SECRETTest plan
docker-build-validationworkflow passes on this PR🤖 Generated with Claude Code