Skip to content

Instantly share code, notes, and snippets.

@garystafford
Last active December 28, 2018 02:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save garystafford/8f01fe83e1d2a139dd23ab0db6d539ea to your computer and use it in GitHub Desktop.
Save garystafford/8f01fe83e1d2a139dd23ab0db6d539ea to your computer and use it in GitHub Desktop.
apiVersion: networking.istio.io/v1alpha3
kind: Gateway
metadata:
name: storefront-gateway
spec:
selector:
istio: ingressgateway
servers:
- port:
number: 80
name: http
protocol: HTTP
hosts:
- api.dev.storefront-demo.com
---
apiVersion: networking.istio.io/v1alpha3
kind: VirtualService
metadata:
name: storefront-dev
spec:
hosts:
- api.dev.storefront-demo.com
gateways:
- storefront-gateway
http:
- match:
- uri:
prefix: /accounts
route:
- destination:
port:
number: 8080
host: accounts.dev.svc.cluster.local
- match:
- uri:
prefix: /fulfillment
route:
- destination:
port:
number: 8080
host: fulfillment.dev.svc.cluster.local
- match:
- uri:
prefix: /orders
route:
- destination:
port:
number: 8080
host: orders.dev.svc.cluster.local
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment