rollouts-plugin-trafficrouter-gatewayapi
rollouts-plugin-trafficrouter-gatewayapi copied to clipboard
Gateway API supports traffic splitting between services in different namespaces, can the plugin also do it?
HttpRoute can split traffic between services in different namespaces.
kind: HTTPRoute
apiVersion: gateway.networking.k8s.io/v1
metadata:
name: argo-rollouts-http-route
namespace: infra
spec:
parentRefs:
- group: gateway.networking.k8s.io
kind: Gateway
name: kong
rules:
- matches:
- path:
type: PathPrefix
value: /fruits
backendRefs:
- name: bananas-echo
port: 1027
kind: Service
namespace: bananas
- name: apples-echo
port: 1027
kind: Service
namespace: apples
The Rollout with this config.
apiVersion: argoproj.io/v1alpha1
kind: Rollout
metadata:
name: rollouts-demo
namespace: default
spec:
replicas: 10
strategy:
canary:
canaryService: bananas-echo # our created canary service
stableService: apples-echo # our created stable service
trafficRouting:
plugins:
argoproj-labs/gatewayAPI:
httpRoute: argo-rollouts-http-route # our created httproute
namespace: infra
I tried to run this but its not able to find the services, I am assuming it does not work because Argo Rollout by itself does not support multi namespace rollout. Is the assumption correct? 🤔
Yes I think your assumption is correct.
Did you take a look at the controller logs for this rollout? Was there an error message?
Sorry I deleted the entire setup from my local but on the Argo Rolllout dashboard, it was complaining about not being able to find both the services as I think Rollout CRD and Service are required to be in the same namespace. The setup was:
Gateway Provider: Kong
Rollout ns: default
HttpRoute ns: infra
Service 1 ns: bananas
Service 2 ns: apples
Appropriate ReferenceGrant was also present.