blob: 561f513da00716ad47f755be627be60d66631f8f [file] [log] [blame]
apiVersion: networking.istio.io/v1alpha3
kind: VirtualService
metadata:
name: all
namespace: testns
spec:
hosts:
- service3.default.svc.cluster.local
- uk.bookinfo.com
- eu.bookinfo.com
gateways:
- my-gateway
- mesh # applies to all the sidecars in the mesh
http:
- match:
- headers:
cookie:
regex: "^(.*?;)?(user=dev-123)(;.*)?"
route:
- destination:
port:
number: 81
host: service3.default.svc.cluster.local
- match:
- uri:
prefix: /reviews/
route:
- destination:
port:
number: 81
host: service3.default.svc.cluster.local
subset: v1
weight: 80
- destination:
host: service3.default.svc.cluster.local
subset: v2
weight: 20