fix(self-hosting): pass AI provider keys through to the web container#2036
Open
DPS0340 wants to merge 1 commit into
Open
fix(self-hosting): pass AI provider keys through to the web container#2036DPS0340 wants to merge 1 commit into
DPS0340 wants to merge 1 commit into
Conversation
self-hosting.mdx tells self-hosters to set DEEPGRAM_API_KEY, GROQ_API_KEY and OPENAI_API_KEY for transcription and AI summaries, and docker-compose.coolify.env.example lists all three, but neither compose file passed them into cap-web. transcribeVideo() returns early on a missing DEEPGRAM_API_KEY and generateAiMetadata() on missing GROQ/OPENAI keys, so both features silently no-op on a self-hosted deployment even when the operator followed the docs.
Author
|
@tembo please review |
Author
|
Same CI note as #2035: Worth approving here specifically — Locally verified both files parse and all three keys resolve to |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Same wiring-gap class as #2035 / #1993, found by sweeping every var in the env schema against both compose files.
Problem
self-hosting.mdxtells self-hosters to set these:and
docker-compose.coolify.env.examplelists all three (lines 64, 67, 68). But neither compose file passes any of them intocap-web, so the operator sets them and nothing happens.The failure is silent, which is what makes it worth fixing rather than just documenting. Both features check the key and return early:
So on a self-hosted instance transcription and AI summaries just never produce output, with no configuration error surfaced to the user — they followed the docs and the feature is simply absent.
Fix
Map the three vars in both compose files, matching how the other optional integrations (
RESEND_API_KEY,GOOGLE_CLIENT_ID,APPLE_CLIENT_SECRET) are already wired.Defaulting to empty via
:-means behaviour is unchanged for anyone not using these: the vars stay unset, the schema treats them asoptional(), and the existing early-returns keep the features off.How I found it
Extracted every uppercase identifier from
packages/env/server.tsand diffed against both compose files. Most of the unmapped ones are legitimately cloud-only (VERCEL_*,STRIPE_*,WORKOS_*,CLOUDFRONT_*,TINYBIRD_*) and shouldn't be in a self-host template. These three are different: the self-hosting docs explicitly instruct users to set them, which makes the omission a bug rather than a scoping decision.CAP_CHROME_EXTENSION_IDwas the fourth in that category and is handled in #2035.Verification
Both files parse as valid YAML and all three keys resolve:
No application code touched.
Diff: 2 files, +6/-0. Independent of #2035 — either can merge first.