Skip to content

Commit

Permalink
vietnam-devs#5 fix proxy
Browse files Browse the repository at this point in the history
  • Loading branch information
thinhnotes committed Aug 8, 2018
1 parent 323743a commit 9264f27
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 16 deletions.
14 changes: 14 additions & 0 deletions deploys/charts/coolstore/templates/cs-gateway.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -96,4 +96,18 @@ spec:
host: cart-service
port:
number: 80
---
apiVersion: networking.istio.io/v1alpha3
kind: ServiceEntry
metadata:
name: external-svc-id
spec:
hosts:
- id.coolstore.local
location: MESH_EXTERNAL
ports:
- number: 80
name: example-http
protocol: HTTP
resolution: DNS
{{- end -}}
30 changes: 15 additions & 15 deletions deploys/k8s/dev-all-in-one.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -424,22 +424,8 @@ spec:
ports:
- containerPort: 8080
---
# Source: coolstore/templates/cs-gateway.yaml
apiVersion: networking.istio.io/v1alpha3
kind: Gateway
metadata:
name: istio-egressgateway
spec:
selector:
istio: egressgateway
servers:
- port:
number: 80
name: http
protocol: HTTP
hosts:
- id.coolstore.local
---
# Source: coolstore/templates/cs-gateway.yaml
apiVersion: networking.istio.io/v1alpha3
kind: Gateway
metadata:
Expand Down Expand Up @@ -538,5 +524,19 @@ spec:
port:
number: 80
---
apiVersion: networking.istio.io/v1alpha3
kind: ServiceEntry
metadata:
name: external-svc-wikipedia
spec:
hosts:
- id.coolstore.local
location: MESH_EXTERNAL
ports:
- number: 80
name: example-http
protocol: HTTP
resolution: DNS
---
# Source: coolstore/templates/nginx-ingress.yaml

2 changes: 1 addition & 1 deletion src/web/proxy.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const config = {
}
if (config.mode == 'production') {
urlSpa = "http://coolstore.local/"
urlIdp = "http://idp-service/"
urlIdp = "http://id.coolstore.local/"
url = "http://api.coolstore.local/"

var urlCat = 'http://api.coolstore.local/catalog/'
Expand Down

0 comments on commit 9264f27

Please sign in to comment.