Skip to content

Commit fffe4ba

Browse files
markturanskyAmbient Code Botclaude
authored
fix(manifests): add gRPC Route for ambient-api-server on mpp-openshift (RHOAIENG-56775) (#1224)
## Summary - Adds missing OpenShift Route `ambient-api-server-grpc` to `components/manifests/overlays/mpp-openshift/ambient-api-server-route.yaml` with `passthrough` TLS termination targeting the `grpc` service port (9000) - Extends `defaultOpenShiftPatterns` in the Go SDK (`go-sdk/client/session_watch.go`) to include `paas.redhat.com`, so `acpctl` correctly derives the gRPC Route hostname on MPP clusters instead of falling back to unreachable pod-IP:9000 ## Root Cause The mpp-openshift overlay only exposed the HTTP Route (port 8000). The gRPC port (9000) had no Route, causing `acpctl session messages -f` and `acpctl get sessions -w` to time out. Additionally, the SDK hostname detection did not recognize `*.apps.int.spoke.dev.us-east-1.aws.paas.redhat.com` as an OpenShift Route pattern. ## Test Plan - [ ] Deploy `kubectl apply -k components/manifests/overlays/mpp-openshift/` and verify `ambient-api-server-grpc` Route is created - [ ] Confirm Route hostname follows pattern `ambient-api-server-grpc-<namespace>.apps.<cluster>.paas.redhat.com` - [ ] Run `acpctl session messages -f <session-id>` against the MPP cluster — should connect without timeout - [ ] Run `acpctl get sessions -w` — should stream watch events Fixes: RHOAIENG-56775 🤖 Generated with [Claude Code](https://claude.ai/code) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added a dedicated gRPC route for the API server that uses re-encrypt TLS and redirects insecure edge traffic. * Enabled gRPC TLS for the API server and configured it to use secret-mounted certificates. * **Infrastructure Updates** * Extended OpenShift hostname matching to recognize additional cloud environment domains. <!-- 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 d6f6ba1 commit fffe4ba

3 files changed

Lines changed: 31 additions & 1 deletion

File tree

components/ambient-sdk/go-sdk/client/session_watch.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ import (
2525

2626
const grpcDefaultPort = "9000"
2727

28-
var defaultOpenShiftPatterns = []string{"apps.rosa", "apps.ocp", "apps.openshift"}
28+
var defaultOpenShiftPatterns = []string{"apps.rosa", "apps.ocp", "apps.openshift", "paas.redhat.com"}
2929

3030
// MessageWatcher streams session messages from a single session via gRPC.
3131
type MessageWatcher struct {

components/manifests/overlays/mpp-openshift/ambient-api-server-args-patch.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,5 +31,16 @@ spec:
3131
- --jwk-cert-file=/configs/authentication/jwks.json
3232
- --enable-grpc=true
3333
- --grpc-server-bindaddress=:9000
34+
- --grpc-enable-tls=true
35+
- --grpc-tls-cert-file=/etc/tls/tls.crt
36+
- --grpc-tls-key-file=/etc/tls/tls.key
3437
- --alsologtostderr
3538
- -v=4
39+
volumeMounts:
40+
- name: tls-certs
41+
mountPath: /etc/tls
42+
readOnly: true
43+
volumes:
44+
- name: tls-certs
45+
secret:
46+
secretName: ambient-api-server-tls

components/manifests/overlays/mpp-openshift/ambient-api-server-route.yaml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,3 +16,22 @@ spec:
1616
tls:
1717
termination: edge
1818
insecureEdgeTerminationPolicy: Redirect
19+
---
20+
apiVersion: route.openshift.io/v1
21+
kind: Route
22+
metadata:
23+
name: ambient-api-server-grpc
24+
namespace: ambient-code--runtime-int
25+
labels:
26+
app: ambient-api-server
27+
component: grpc
28+
shard: internal
29+
spec:
30+
to:
31+
kind: Service
32+
name: ambient-api-server
33+
port:
34+
targetPort: grpc
35+
tls:
36+
termination: reencrypt
37+
insecureEdgeTerminationPolicy: Redirect

0 commit comments

Comments
 (0)