Skip to content

fix: correct API server deployment manifests for gRPC, health checks, and auth mock#787

Open
markturansky wants to merge 2 commits intoambient-code:mainfrom
markturansky:fix/grpc_service_fixes
Open

fix: correct API server deployment manifests for gRPC, health checks, and auth mock#787
markturansky wants to merge 2 commits intoambient-code:mainfrom
markturansky:fix/grpc_service_fixes

Conversation

@markturansky
Copy link
Contributor

Summary

  • Remove unsupported --enable-sentry flag that was causing pod crash loops (unknown flag in rh-trex-ai v0.0.14)
  • Add gRPC server support: --enable-grpc=true, --grpc-server-bindaddress=:9000, service port 9000, and gRPC routes across base and overlay manifests
  • Fix liveness probe path from /api/ambient-api-server to /api/ambient
  • Fix environment variable from OCM_ENV to AMBIENT_ENV
  • Set enable-mock=true in production environment and service template to avoid crash when API client secret files are absent

Files Changed

  • components/ambient-api-server/cmd/ambient-api-server/environments/e_production.go — enable-mock default to true
  • components/ambient-api-server/templates/service-template.yml — ENABLE_AUTHZ_MOCK default to true
  • components/ambient-api-server/templates/route-template.yml — added gRPC route
  • components/manifests/base/ambient-api-server-service.yml — removed sentry, added gRPC, fixed probe & env var
  • components/manifests/base/ambient-api-server-route.yml — added gRPC route
  • components/manifests/overlays/local-dev/ambient-api-server-route.yaml — added gRPC route
  • components/manifests/overlays/production/ambient-api-server-route.yaml — added gRPC route

Test plan

  • Verify API server pod starts without crash loops on OpenShift
  • Verify liveness probe passes (pod shows 1/1 Ready)
  • Verify gRPC route is accessible from control plane
  • Verify REST API route responds on /api/ambient

🤖 Generated with Claude Code

… and auth mock

- Remove unsupported --enable-sentry flag from deployment manifest
- Add gRPC server flags (--enable-grpc=true, --grpc-server-bindaddress=:9000)
- Add gRPC service port and route definitions across base and overlays
- Fix liveness probe path from /api/ambient-api-server to /api/ambient
- Fix environment variable from OCM_ENV to AMBIENT_ENV
- Set enable-mock=true in production environment to skip missing API client secrets
- Update ENABLE_AUTHZ_MOCK default to true in service template

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
"v": "1",
"debug": "false",
"enable-mock": "false",
"enable-mock": "true",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this enable-mock is poorly named (mock for what?), but it's for the authz stub in the stack.

Project.ID now equals Project.Name (the Kubernetes namespace), making
project_id a human-readable namespace reference throughout sessions
and project_settings instead of an opaque KSUID.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant