forked from pytorch/serve
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvirtual_service.yaml
36 lines (36 loc) · 884 Bytes
/
virtual_service.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
apiVersion: networking.istio.io/v1alpha3
kind: VirtualService
metadata:
name: torchserve-vs
spec:
hosts:
- "*"
gateways:
- torchserve-gw
http:
- match:
- uri:
prefix: /metrics
route:
- destination:
host: torchserve.default.svc.cluster.local
port:
number: 8082
- match:
- headers:
protocol:
exact: REST
route:
- destination:
host: torchserve.default.svc.cluster.local # <ts-service-name>.<namespace>.svc.cluster.local
port:
number: 8080
- match:
- headers:
protocol:
exact: gRPC
route:
- destination:
host: torchserve.default.svc.cluster.local # <ts-service-name>.<namespace>.svc.cluster.local
port:
number: 7070