Skip to content

Commit a4cf942

Browse files
markturanskyAmbient Code Botclaude
committed
fix(control-plane): default BackendURL to AMBIENT_API_SERVER_URL (#1204)
## Summary The `BackendURL` config field defaulted to `http://backend-service.ambient-code.svc:8080/api` — a legacy service that no longer exists. Runner pods need `BACKEND_API_URL` set to call `GET /credentials/{id}/token`. Since `AMBIENT_API_SERVER_URL` is already set in all deployments, default `BackendURL` to it. Discovered during E2E testing of the credential flow on OSD `ambient-s0`: runner logs showed DNS failures fetching credentials from the old backend URL. ## Test plan - [ ] Runner pod logs show `Successfully fetched github credentials from backend` instead of DNS failure on `backend-service.ambient-code.svc` - [ ] Agent can retrieve GitHub token via `/credentials/{id}/token` and use it 🤖 Generated with [Claude Code](https://claude.ai/code) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Chores** * Backend URL configuration now uses environment variable fallback logic (`BACKEND_API_URL` → `AMBIENT_API_SERVER_URL` → default to `http://localhost:8000`), enabling more flexible configuration across different deployment environments. <!-- end of auto-generated comment: release notes by coderabbit.ai --> Co-authored-by: Ambient Code Bot <bot@ambient-code.local> Co-authored-by: Claude <noreply@anthropic.com>
1 parent 085028b commit a4cf942

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • components/ambient-control-plane/internal/config

components/ambient-control-plane/internal/config/config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ func Load() (*ControlPlaneConfig, error) {
5757
Reconcilers: parseReconcilers(envOrDefault("RECONCILERS", "tally,kube")),
5858
RunnerImage: envOrDefault("RUNNER_IMAGE", "quay.io/ambient_code/vteam_claude_runner:latest"),
5959
RunnerGRPCUseTLS: os.Getenv("AMBIENT_GRPC_USE_TLS") == "true",
60-
BackendURL: envOrDefault("BACKEND_API_URL", "http://backend-service.ambient-code.svc:8080/api"),
60+
BackendURL: envOrDefault("BACKEND_API_URL", envOrDefault("AMBIENT_API_SERVER_URL", "http://localhost:8000")),
6161
Namespace: envOrDefault("NAMESPACE", "ambient-code"),
6262
AnthropicAPIKey: os.Getenv("ANTHROPIC_API_KEY"),
6363
VertexEnabled: os.Getenv("USE_VERTEX") == "1" || os.Getenv("USE_VERTEX") == "true",

0 commit comments

Comments
 (0)