Pass HTTP MCP server secrets to gateway container#11185
Merged
Conversation
Added environment variable pass-through to fix Daily News workflow failures. HTTP MCP secrets (like TAVILY_API_KEY) are now correctly passed to the gateway Docker container via -e flags. Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix Daily News workflow failure due to missing TAVILY_API_KEY
Pass HTTP MCP server secrets to gateway container
Jan 22, 2026
14 tasks
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.
HTTP MCP server secrets (e.g.,
TAVILY_API_KEY) were collected from workflow frontmatter but not passed to the gateway Docker container, causing initialization failures in 6 workflows.Root Cause
The MCP setup generator added secrets to the workflow step's
env:block but omitted them from the Docker container's-eflags:Changes
pkg/workflow/mcp_setup_generator.go-eflagsBefore:
After:
Tests:
TestHTTPMCPSecretsPassedToGatewayContainer- single server caseTestMultipleHTTPMCPSecretsPassedToGatewayContainer- multiple serversImpact
Affects 6 workflows using
shared/mcp/tavily.md: daily-news, mcp-inspector, research, scout, smoke-claude, smoke-codex.Note: Repository secret
TAVILY_API_KEYmust still be added separately for workflows to succeed.Original prompt
This section details on the original issue you should resolve
<issue_title>Daily News Workflow Failing: Missing TAVILY_API_KEY Secret</issue_title>
<issue_description>### Summary
The Daily News workflow has failed 10 consecutive runs (100% failure rate) due to a missing repository secret.
Status: 🚨 CRITICAL - Fix available and actionable
Last Success: Run #98 (2026-01-08)
Failure Duration: 10+ days
Affected Workflows: 6 total (daily-news, mcp-inspector, research, scout, smoke-claude, smoke-codex)
Root Cause
Missing
TAVILY_API_KEYrepository secretThe Daily News workflow includes the shared MCP server configuration
shared/mcp/tavily.md, which requires:Error Evidence:
"undefined environment variable referenced: TAVILY_API_KEY"Impact
Primary Impact: Daily News workflow cannot generate daily repository digests
Secondary Impact: 5 additional workflows potentially affected:
All 6 workflows include
shared/mcp/tavily.mdand require the same secret.Solution (RECOMMENDED): Add Repository Secret
Timeline: 5-10 minutes
Complexity: Low
Steps:
TAVILY_API_KEYExpected Outcome:
Alternative Solutions
Option 2: Remove Tavily Dependency (15-20 minutes)
If Tavily API access is not available:
.github/workflows/daily-news.mdand remove the Tavily import linemake recompileTrade-off: Loses Tavily search capabilities, but workflow becomes operational
Option 3: Deprecate Workflow (5 minutes)
If Daily News is no longer needed:
Trade-off: User-facing daily digest feature lost
Verification Plan
After adding the secret:
Immediate: Trigger manual run via workflow_dispatch
Next Day: Monitor scheduled run (9am UTC)
Follow-up: Check status of other 5 Tavily-dependent workflows
Recent Run History
Pattern: Consistent failure at MCP gateway initialization (Step 31), rapid failure (~90s), no agent execution.
Context
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.