Skip to content

Commit

Permalink
chore: Add example for istio-subset-split
Browse files Browse the repository at this point in the history
Signed-off-by: iam-veeramalla <abhishek.veeramalla@gmail.com>
  • Loading branch information
iam-veeramalla committed Oct 12, 2022
1 parent a0d8eb5 commit 6556034
Showing 1 changed file with 89 additions and 0 deletions.
89 changes: 89 additions & 0 deletions examples/traffic-routing/istio-subset-split.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
# This examples sets up istio-subset-split
apiVersion: v1
kind: Service
metadata:
name: istio-subset-split
spec:
ports:
- port: 80
targetPort: http
protocol: TCP
name: http
selector:
app: istio-subset-split

---
apiVersion: networking.istio.io/v1alpha3
kind: VirtualService
metadata:
name: istio-subset-split-vsvc
spec:
hosts:
- istio-subset-split
http:
- name: primary
route:
- destination:
host: istio-subset-split
subset: stable
weight: 100
- destination:
host: istio-subset-split
subset: canary
weight: 0

---
apiVersion: networking.istio.io/v1alpha3
kind: DestinationRule
metadata:
name: istio-subset-split-destrule
spec:
host: istio-subset-split
subsets:
- name: stable
labels:
app: istio-subset-split
- name: canary
labels:
app: istio-subset-split

---
apiVersion: argoproj.io/v1alpha1
kind: Rollout
metadata:
name: istio-subset-split
spec:
strategy:
canary:
trafficRouting:
istio:
virtualService:
name: istio-subset-split-vsvc
routes:
- primary
destinationRule:
name: istio-subset-split-destrule
canarySubsetName: canary
stableSubsetName: stable
steps:
- setWeight: 10
- pause: {}
selector:
matchLabels:
app: istio-subset-split
template:
metadata:
labels:
app: istio-subset-split
spec:
containers:
- name: istio-subset-split
image: nginx:1.19-alpine
ports:
- name: http
containerPort: 80
protocol: TCP
resources:
requests:
memory: 16Mi
cpu: 5m

0 comments on commit 6556034

Please sign in to comment.