update gateway spec
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
# ------------------------------------------------------------------------------
|
||||
# HTTPRoute — Grafana via Cilium Gateway
|
||||
# Cert issued per-service via cert-manager annotation on the Certificate
|
||||
# ------------------------------------------------------------------------------
|
||||
apiVersion: cert-manager.io/v1
|
||||
kind: Certificate
|
||||
@@ -25,12 +24,21 @@ metadata:
|
||||
external-dns.alpha.kubernetes.io/target: "10.1.71.90"
|
||||
spec:
|
||||
parentRefs:
|
||||
- name: fastpass-gateway
|
||||
- group: gateway.networking.k8s.io
|
||||
kind: Gateway
|
||||
name: fastpass-gateway
|
||||
namespace: gateway
|
||||
sectionName: https
|
||||
hostnames:
|
||||
- grafana.local.mk-labs.cloud
|
||||
rules:
|
||||
- backendRefs:
|
||||
- name: monitoring-grafana
|
||||
- matches:
|
||||
- path:
|
||||
type: PathPrefix
|
||||
value: /
|
||||
backendRefs:
|
||||
- group: ""
|
||||
kind: Service
|
||||
name: monitoring-grafana
|
||||
port: 80
|
||||
weight: 1
|
||||
|
||||
@@ -307,22 +307,40 @@ cluster/applications/<app-name>/
|
||||
|
||||
### 3. HTTPRoute pattern
|
||||
|
||||
Every HTTPRoute needs two annotations for DNS and routing to work:
|
||||
Always include all fields explicitly — Cilium defaults `group`, `kind`, `weight`,
|
||||
and `matches` at reconcile time, causing ArgoCD out-of-sync if omitted.
|
||||
|
||||
Full HTTPRoute template:
|
||||
|
||||
```yaml
|
||||
apiVersion: gateway.networking.k8s.io/v1
|
||||
kind: HTTPRoute
|
||||
metadata:
|
||||
name: <service>
|
||||
namespace: <app-namespace>
|
||||
annotations:
|
||||
external-dns.alpha.kubernetes.io/hostname: <service>.local.mk-labs.cloud
|
||||
external-dns.alpha.kubernetes.io/target: "10.1.71.90"
|
||||
```
|
||||
|
||||
And a parentRef pointing at the platform Gateway:
|
||||
|
||||
```yaml
|
||||
spec:
|
||||
parentRefs:
|
||||
- name: fastpass-gateway
|
||||
- group: gateway.networking.k8s.io
|
||||
kind: Gateway
|
||||
name: fastpass-gateway
|
||||
namespace: gateway
|
||||
sectionName: https
|
||||
hostnames:
|
||||
- <service>.local.mk-labs.cloud
|
||||
rules:
|
||||
- matches:
|
||||
- path:
|
||||
type: PathPrefix
|
||||
value: /
|
||||
backendRefs:
|
||||
- group: ""
|
||||
kind: Service
|
||||
name: <service>
|
||||
port: <port>
|
||||
weight: 1
|
||||
```
|
||||
|
||||
### 4. Per-service certificate
|
||||
|
||||
Reference in New Issue
Block a user