Browse Source

Final charts tunning and allowing Linkerd Mesh to be used

features/migration-dotnet3
eiximenis 5 years ago
parent
commit
a2053deb49
64 changed files with 399 additions and 1313 deletions
  1. +0
    -34
      k8s/helm/apigwmm/configuration-mobile-marketing.json
  2. +49
    -0
      k8s/helm/apigwmm/envoy.yaml
  3. +0
    -21
      k8s/helm/apigwmm/templates/configmap.yaml
  4. +6
    -6
      k8s/helm/apigwmm/templates/deployment.yaml
  5. +2
    -2
      k8s/helm/apigwmm/templates/envoy-cm.yaml
  6. +6
    -42
      k8s/helm/apigwmm/values.yaml
  7. +0
    -142
      k8s/helm/apigwms/configuration-mobile-shopping.json
  8. +80
    -0
      k8s/helm/apigwms/envoy.yaml
  9. +0
    -21
      k8s/helm/apigwms/templates/configmap.yaml
  10. +6
    -6
      k8s/helm/apigwms/templates/deployment.yaml
  11. +2
    -2
      k8s/helm/apigwms/templates/envoy-cm.yaml
  12. +6
    -42
      k8s/helm/apigwms/values.yaml
  13. +0
    -34
      k8s/helm/apigwwm/configuration-web-marketing.json
  14. +49
    -0
      k8s/helm/apigwwm/envoy.yaml
  15. +0
    -21
      k8s/helm/apigwwm/templates/configmap.yaml
  16. +6
    -6
      k8s/helm/apigwwm/templates/deployment.yaml
  17. +2
    -2
      k8s/helm/apigwwm/templates/envoy-cm.yaml
  18. +6
    -41
      k8s/helm/apigwwm/values.yaml
  19. +0
    -166
      k8s/helm/apigwws/configuration-web-shopping.json
  20. +80
    -0
      k8s/helm/apigwws/envoy.yaml
  21. +0
    -21
      k8s/helm/apigwws/templates/configmap.yaml
  22. +5
    -5
      k8s/helm/apigwws/templates/deployment.yaml
  23. +2
    -2
      k8s/helm/apigwws/templates/envoy-cm.yaml
  24. +6
    -41
      k8s/helm/apigwws/values.yaml
  25. +10
    -10
      k8s/helm/app.yaml
  26. +4
    -0
      k8s/helm/basket-api/templates/deployment.yaml
  27. +4
    -19
      k8s/helm/catalog-api/templates/deployment.yaml
  28. +1
    -1
      k8s/helm/catalog-api/templates/service.yaml
  29. +22
    -9
      k8s/helm/deploy-all.ps1
  30. +4
    -0
      k8s/helm/identity-api/templates/deployment.yaml
  31. +2
    -0
      k8s/helm/inf.yaml
  32. +4
    -0
      k8s/helm/locations-api/templates/deployment.yaml
  33. +4
    -0
      k8s/helm/marketing-api/templates/deployment.yaml
  34. +4
    -0
      k8s/helm/mobileshoppingagg/templates/deployment.yaml
  35. +4
    -0
      k8s/helm/ordering-api/templates/deployment.yaml
  36. +1
    -1
      k8s/helm/ordering-api/templates/service.yaml
  37. +4
    -0
      k8s/helm/payment-api/templates/deployment.yaml
  38. +4
    -0
      k8s/helm/webhooks-api/templates/deployment.yaml
  39. +4
    -0
      k8s/helm/webhooks-web/templates/deployment.yaml
  40. +4
    -0
      k8s/helm/webmvc/templates/deployment.yaml
  41. +4
    -0
      k8s/helm/webstatus/templates/deployment.yaml
  42. +0
    -34
      k8s/ocelot/configuration-mobile-marketing.json
  43. +0
    -142
      k8s/ocelot/configuration-mobile-shopping.json
  44. +0
    -34
      k8s/ocelot/configuration-web-marketing.json
  45. +0
    -154
      k8s/ocelot/configuration-web-shopping.json
  46. +0
    -155
      k8s/ocelot/deployment.yaml
  47. +0
    -55
      k8s/ocelot/service.yaml
  48. +0
    -1
      src/ApiGateways/Mobile.Bff.Shopping/aggregator/Dockerfile
  49. +0
    -1
      src/ApiGateways/Web.Bff.Shopping/aggregator/Dockerfile
  50. +0
    -1
      src/Services/Basket/Basket.API/Dockerfile
  51. +0
    -1
      src/Services/Catalog/Catalog.API/Dockerfile
  52. +0
    -1
      src/Services/Identity/Identity.API/Dockerfile
  53. +0
    -1
      src/Services/Location/Locations.API/Dockerfile
  54. +0
    -1
      src/Services/Marketing/Marketing.API/Dockerfile
  55. +0
    -1
      src/Services/Ordering/Ordering.API/Dockerfile
  56. +0
    -1
      src/Services/Ordering/Ordering.BackgroundTasks/Dockerfile
  57. +0
    -1
      src/Services/Ordering/Ordering.SignalrHub/Dockerfile
  58. +0
    -1
      src/Services/Payment/Payment.API/Dockerfile
  59. +0
    -1
      src/Services/Webhooks/Webhooks.API/Dockerfile
  60. +0
    -1
      src/Web/WebMVC/Dockerfile
  61. +0
    -1
      src/Web/WebSPA/Dockerfile
  62. +0
    -1
      src/Web/WebStatus/Dockerfile
  63. +0
    -1
      src/Web/WebhookClient/Dockerfile
  64. +2
    -26
      src/docker-compose.yml

+ 0
- 34
k8s/helm/apigwmm/configuration-mobile-marketing.json View File

@ -1,34 +0,0 @@
{
"ReRoutes": [
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "marketing",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/m/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "locations",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/l/{everything}",
"UpstreamHttpMethod": []
}
],
"GlobalConfiguration": {
"RequestIdKey": "OcRequestId",
"AdministrationPath": "/administration"
}
}

+ 49
- 0
k8s/helm/apigwmm/envoy.yaml View File

@ -0,0 +1,49 @@
admin:
access_log_path: "/dev/null"
address:
socket_address:
address: 0.0.0.0
port_value: 8001
static_resources:
listeners:
- address:
socket_address:
address: 0.0.0.0
port_value: 80
filter_chains:
- filters:
- name: envoy.http_connection_manager
config:
codec_type: auto
stat_prefix: ingress_http
route_config:
name: eshop_backend_route
virtual_hosts:
- name: eshop_backend
domains:
- "*"
routes:
- match:
prefix: "/api/v1/m/"
route:
prefix_rewrite: "/api/v1/"
cluster: marketing
http_filters:
- name: envoy.router
clusters:
- name: marketing
connect_timeout: 0.25s
type: logical_dns
lb_policy: round_robin
hosts:
- socket_address:
address: marketing-api
port_value: 80
- name: locations
connect_timeout: 0.25s
type: logical_dns
lb_policy: round_robin
hosts:
- socket_address:
address: locations-api
port_value: 80

+ 0
- 21
k8s/helm/apigwmm/templates/configmap.yaml View File

@ -1,21 +0,0 @@
{{- $name := include "apigwmm.fullname" . -}}
apiVersion: v1
kind: ConfigMap
metadata:
name: "cfg-{{ $name }}"
labels:
app: {{ template "apigwmm.name" . }}
chart: {{ template "apigwmm.chart" .}}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
data:
internalurls__identity: http://{{ .Values.app.svc.identity }}
internalurls__basket__hc: http://{{ .Values.app.svc.basket }}/hc
internalurls__catalog__hc: http://{{ .Values.app.svc.catalog }}/hc
internalurls__identity__hc: http://{{ .Values.app.svc.identity }}/hc
internalurls__ordering__hc: http://{{ .Values.app.svc.ordering }}/hc
internalurls__marketing__hc: http://{{ .Values.app.svc.marketing }}/hc
internalurls__payment__hc: http://{{ .Values.app.svc.payment }}/hc
internalurls__location__hc: http://{{ .Values.app.svc.locations }}/hc

+ 6
- 6
k8s/helm/apigwmm/templates/deployment.yaml View File

@ -1,6 +1,6 @@
{{- $name := include "apigwmm.fullname" . -}}
{{- $cfgname := printf "%s-%s" "cfg" $name -}}
{{- $ocelotcfgname := printf "%s-%s" "ocelot" $name -}}
{{- $envoycfgname := printf "%s-%s" "envoy" $name -}}
apiVersion: apps/v1beta2
kind: Deployment
metadata:
@ -30,10 +30,10 @@ spec:
volumes:
- name: config
configMap:
name: {{ $ocelotcfgname }}
name: {{ $envoycfgname }}
items:
- key: configuration-mobile-marketing.json
path: configuration.json
- key: envoy.yaml
path: envoy.yaml
containers:
- name: {{ .Chart.Name }}
{{ if .Values.probes -}}
@ -58,10 +58,10 @@ spec:
{{- end -}}
{{- end }}
image: "{{ template "fqdn-image" . }}:{{ .Values.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
imagePullPolicy: IfNotPresent
volumeMounts:
- name: config
mountPath: {{ .Values.ocelot.configPath }}
mountPath: {{ .Values.envoy.configPath }}
env:
- name: PATH_BASE
value: {{ include "pathBase" . }}


k8s/helm/apigwmm/templates/ocelot-cm.yaml → k8s/helm/apigwmm/templates/envoy-cm.yaml View File

@ -3,12 +3,12 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: "ocelot-{{ $name }}"
name: "envoy-{{ $name }}"
labels:
app: {{ template "apigwmm.name" . }}
chart: {{ template "apigwmm.chart" .}}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
data:
{{ (.Files.Glob "configuration-mobile-marketing.json").AsConfig | indent 2 }}
{{ (.Files.Glob "envoy.yaml").AsConfig | indent 2 }}

+ 6
- 42
k8s/helm/apigwmm/values.yaml View File

@ -3,9 +3,8 @@ clusterName: eshop-aks
pathBase: /mobilemarketingapigw
image:
repository: eshop/ocelotapigw
tag: latest
pullPolicy: IfNotPresent
repository: envoyproxy/envoy
tag: v1.11.1
service:
type: ClusterIP
@ -25,42 +24,7 @@ tolerations: []
affinity: {}
# env defines the environment variables that will be declared in the pod
env:
urls:
# configmap declares variables which value is taken from the config map defined in template configmap.yaml (name is name of var and key the key in configmap).
configmap:
- name: IdentityUrl
key: internalurls__identity
- name: CatalogUrlHC
key: internalurls__catalog__hc
- name: BasketUrlHC
key: internalurls__basket__hc
- name: IdentityUrlHC
key: internalurls__identity__hc
- name: OrderingUrlHC
key: internalurls__ordering__hc
- name: MarketingUrlHC
key: internalurls__marketing__hc
- name: PaymentUrlHC
key: internalurls__payment__hc
- name: LocationUrlHC
key: internalurls__location__hc
# values define environment variables with a fixed value (no configmap involved) (name is name of var, and value is its value)
values:
- name: ASPNETCORE_ENVIRONMENT
value: Development
probes:
liveness:
path: /liveness
initialDelaySeconds: 10
periodSeconds: 15
port: 80
readiness:
path: /hc
timeoutSeconds: 5
initialDelaySeconds: 90
periodSeconds: 60
port: 80
ocelot:
configPath: /app/configuration
env: {}
envoy:
configPath: /etc/envoy

+ 0
- 142
k8s/helm/apigwms/configuration-mobile-shopping.json View File

@ -1,142 +0,0 @@
{
"ReRoutes": [
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "catalog",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/c/{everything}",
"UpstreamHttpMethod": [ "GET" ]
},
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "basket",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/b/{everything}",
"UpstreamHttpMethod": [],
"AuthenticationOptions": {
"AuthenticationProviderKey": "IdentityApiKey",
"AllowedScopes": []
}
},
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "ordering",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/o/{everything}",
"UpstreamHttpMethod": [],
"AuthenticationOptions": {
"AuthenticationProviderKey": "IdentityApiKey",
"AllowedScopes": []
}
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "mobileshoppingagg",
"Port": 80
}
],
"UpstreamPathTemplate": "/{everything}",
"UpstreamHttpMethod": [ "POST", "PUT", "GET" ],
"AuthenticationOptions": {
"AuthenticationProviderKey": "IdentityApiKey",
"AllowedScopes": []
}
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "ordering",
"Port": 80
}
],
"UpstreamPathTemplate": "/orders-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "basket",
"Port": 80
}
],
"UpstreamPathTemplate": "/basket-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "catalog",
"Port": 80
}
],
"UpstreamPathTemplate": "/catalog-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "marketing",
"Port": 80
}
],
"UpstreamPathTemplate": "/marketing-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "payment",
"Port": 80
}
],
"UpstreamPathTemplate": "/payment-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "locations.api",
"Port": 80
}
],
"UpstreamPathTemplate": "/location-api/{everything}",
"UpstreamHttpMethod": []
}
],
"GlobalConfiguration": {
"RequestIdKey": "OcRequestId",
"AdministrationPath": "/administration"
}
}

+ 80
- 0
k8s/helm/apigwms/envoy.yaml View File

@ -0,0 +1,80 @@
admin:
access_log_path: "/dev/null"
address:
socket_address:
address: 0.0.0.0
port_value: 8001
static_resources:
listeners:
- address:
socket_address:
address: 0.0.0.0
port_value: 80
filter_chains:
- filters:
- name: envoy.http_connection_manager
config:
codec_type: auto
stat_prefix: ingress_http
route_config:
name: eshop_backend_route
virtual_hosts:
- name: eshop_backend
domains:
- "*"
routes:
- match:
prefix: "/api/v1/c/"
route:
prefix_rewrite: "/api/v1/"
cluster: catalog
- match:
prefix: "/api/v1/o/"
route:
prefix_rewrite: "/api/v1/"
cluster: ordering
- match:
prefix: "/api/v1/b/"
route:
prefix_rewrite: "/api/v1/"
cluster: basket
- match:
prefix: "/"
route:
prefix_rewrite: "/"
cluster: shoppingagg
http_filters:
- name: envoy.router
clusters:
- name: shoppingagg
connect_timeout: 0.25s
type: logical_dns
lb_policy: round_robin
hosts:
- socket_address:
address: webshoppingagg
port_value: 80
- name: catalog
connect_timeout: 0.25s
type: logical_dns
lb_policy: round_robin
hosts:
- socket_address:
address: catalog-api
port_value: 80
- name: basket
connect_timeout: 0.25s
type: logical_dns
lb_policy: round_robin
hosts:
- socket_address:
address: basket-api
port_value: 80
- name: ordering
connect_timeout: 0.25s
type: logical_dns
lb_policy: round_robin
hosts:
- socket_address:
address: ordering-api
port_value: 80

+ 0
- 21
k8s/helm/apigwms/templates/configmap.yaml View File

@ -1,21 +0,0 @@
{{- $name := include "apigwms.fullname" . -}}
apiVersion: v1
kind: ConfigMap
metadata:
name: "cfg-{{ $name }}"
labels:
app: {{ template "apigwms.name" . }}
chart: {{ template "apigwms.chart" .}}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
data:
internalurls__identity: http://{{ .Values.app.svc.identity }}
internalurls__basket__hc: http://{{ .Values.app.svc.basket }}/hc
internalurls__catalog__hc: http://{{ .Values.app.svc.catalog }}/hc
internalurls__identity__hc: http://{{ .Values.app.svc.identity }}/hc
internalurls__ordering__hc: http://{{ .Values.app.svc.ordering }}/hc
internalurls__marketing__hc: http://{{ .Values.app.svc.marketing }}/hc
internalurls__payment__hc: http://{{ .Values.app.svc.payment }}/hc
internalurls__location__hc: http://{{ .Values.app.svc.locations }}/hc

+ 6
- 6
k8s/helm/apigwms/templates/deployment.yaml View File

@ -1,6 +1,6 @@
{{- $name := include "apigwms.fullname" . -}}
{{- $cfgname := printf "%s-%s" "cfg" $name -}}
{{- $ocelotcfgname := printf "%s-%s" "ocelot" $name -}}
{{- $envoycfgname := printf "%s-%s" "envoy" $name -}}
apiVersion: apps/v1beta2
kind: Deployment
metadata:
@ -30,10 +30,10 @@ spec:
volumes:
- name: config
configMap:
name: {{ $ocelotcfgname }}
name: {{ $envoycfgname }}
items:
- key: configuration-mobile-shopping.json
path: configuration.json
- key: envoy.yaml
path: envoy.yaml
containers:
- name: {{ .Chart.Name }}
{{ if .Values.probes -}}
@ -58,10 +58,10 @@ spec:
{{- end -}}
{{- end }}
image: "{{ template "fqdn-image" . }}:{{ .Values.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
imagePullPolicy: IfNotPresent
volumeMounts:
- name: config
mountPath: {{ .Values.ocelot.configPath }}
mountPath: {{ .Values.envoy.configPath }}
env:
- name: PATH_BASE
value: {{ include "pathBase" . }}


k8s/helm/apigwms/templates/ocelot-cm.yaml → k8s/helm/apigwms/templates/envoy-cm.yaml View File

@ -3,12 +3,12 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: "ocelot-{{ $name }}"
name: "envoy-{{ $name }}"
labels:
app: {{ template "apigwms.name" . }}
chart: {{ template "apigwms.chart" .}}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
data:
{{ (.Files.Glob "configuration-mobile-shopping.json").AsConfig | indent 2 }}
{{ (.Files.Glob "envoy.yaml").AsConfig | indent 2 }}

+ 6
- 42
k8s/helm/apigwms/values.yaml View File

@ -3,9 +3,8 @@ clusterName: eshop-aks
pathBase: /mobileshoppingapigw
image:
repository: eshop/ocelotapigw
tag: latest
pullPolicy: IfNotPresent
repository: envoyproxy/envoy
tag: v1.11.1
service:
type: ClusterIP
@ -25,42 +24,7 @@ tolerations: []
affinity: {}
# env defines the environment variables that will be declared in the pod
env:
urls:
# configmap declares variables which value is taken from the config map defined in template configmap.yaml (name is name of var and key the key in configmap).
configmap:
- name: IdentityUrl
key: internalurls__identity
- name: CatalogUrlHC
key: internalurls__catalog__hc
- name: BasketUrlHC
key: internalurls__basket__hc
- name: IdentityUrlHC
key: internalurls__identity__hc
- name: OrderingUrlHC
key: internalurls__ordering__hc
- name: MarketingUrlHC
key: internalurls__marketing__hc
- name: PaymentUrlHC
key: internalurls__payment__hc
- name: LocationUrlHC
key: internalurls__location__hc
# values define environment variables with a fixed value (no configmap involved) (name is name of var, and value is its value)
values:
- name: ASPNETCORE_ENVIRONMENT
value: Development
probes:
liveness:
path: /liveness
initialDelaySeconds: 10
periodSeconds: 15
port: 80
readiness:
path: /hc
timeoutSeconds: 5
initialDelaySeconds: 90
periodSeconds: 60
port: 80
ocelot:
configPath: /app/configuration
env: {}
envoy:
configPath: /etc/envoy

+ 0
- 34
k8s/helm/apigwwm/configuration-web-marketing.json View File

@ -1,34 +0,0 @@
{
"ReRoutes": [
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "marketing",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/m/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "locations",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/l/{everything}",
"UpstreamHttpMethod": []
}
],
"GlobalConfiguration": {
"RequestIdKey": "OcRequestId",
"AdministrationPath": "/administration"
}
}

+ 49
- 0
k8s/helm/apigwwm/envoy.yaml View File

@ -0,0 +1,49 @@
admin:
access_log_path: "/dev/null"
address:
socket_address:
address: 0.0.0.0
port_value: 8001
static_resources:
listeners:
- address:
socket_address:
address: 0.0.0.0
port_value: 80
filter_chains:
- filters:
- name: envoy.http_connection_manager
config:
codec_type: auto
stat_prefix: ingress_http
route_config:
name: eshop_backend_route
virtual_hosts:
- name: eshop_backend
domains:
- "*"
routes:
- match:
prefix: "/api/v1/m/"
route:
prefix_rewrite: "/api/v1/"
cluster: marketing
http_filters:
- name: envoy.router
clusters:
- name: marketing
connect_timeout: 0.25s
type: logical_dns
lb_policy: round_robin
hosts:
- socket_address:
address: marketing-api
port_value: 80
- name: locations
connect_timeout: 0.25s
type: logical_dns
lb_policy: round_robin
hosts:
- socket_address:
address: locations-api
port_value: 80

+ 0
- 21
k8s/helm/apigwwm/templates/configmap.yaml View File

@ -1,21 +0,0 @@
{{- $name := include "apigwwm.fullname" . -}}
apiVersion: v1
kind: ConfigMap
metadata:
name: "cfg-{{ $name }}"
labels:
app: {{ template "apigwwm.name" . }}
chart: {{ template "apigwwm.chart" .}}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
data:
internalurls__identity: http://{{ .Values.app.svc.identity }}
internalurls__basket__hc: http://{{ .Values.app.svc.basket }}/hc
internalurls__catalog__hc: http://{{ .Values.app.svc.catalog }}/hc
internalurls__identity__hc: http://{{ .Values.app.svc.identity }}/hc
internalurls__ordering__hc: http://{{ .Values.app.svc.ordering }}/hc
internalurls__marketing__hc: http://{{ .Values.app.svc.marketing }}/hc
internalurls__payment__hc: http://{{ .Values.app.svc.payment }}/hc
internalurls__location__hc: http://{{ .Values.app.svc.locations }}/hc

+ 6
- 6
k8s/helm/apigwwm/templates/deployment.yaml View File

@ -1,6 +1,6 @@
{{- $name := include "apigwwm.fullname" . -}}
{{- $cfgname := printf "%s-%s" "cfg" $name -}}
{{- $ocelotcfgname := printf "%s-%s" "ocelot" $name -}}
{{- $envoycfgname := printf "%s-%s" "envoy" $name -}}
apiVersion: apps/v1beta2
kind: Deployment
metadata:
@ -30,10 +30,10 @@ spec:
volumes:
- name: config
configMap:
name: {{ $ocelotcfgname }}
name: {{ $envoycfgname }}
items:
- key: configuration-web-marketing.json
path: configuration.json
- key: envoy.yaml
path: envoy.yaml
containers:
- name: {{ .Chart.Name }}
{{ if .Values.probes -}}
@ -58,10 +58,10 @@ spec:
{{- end -}}
{{- end }}
image: "{{ template "fqdn-image" . }}:{{ .Values.image.tag }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
imagePullPolicy: IfNotPresent
volumeMounts:
- name: config
mountPath: {{ .Values.ocelot.configPath }}
mountPath: {{ .Values.envoy.configPath }}
env:
- name: PATH_BASE
value: {{ include "pathBase" . }}


k8s/helm/apigwwm/templates/ocelot-cm.yaml → k8s/helm/apigwwm/templates/envoy-cm.yaml View File

@ -3,12 +3,12 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: "ocelot-{{ $name }}"
name: "envoy-{{ $name }}"
labels:
app: {{ template "apigwwm.name" . }}
chart: {{ template "apigwwm.chart" .}}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
data:
{{ (.Files.Glob "configuration-web-marketing.json").AsConfig | indent 2 -}}
{{ (.Files.Glob "envoy.yaml").AsConfig | indent 2 -}}

+ 6
- 41
k8s/helm/apigwwm/values.yaml View File

@ -3,9 +3,8 @@ clusterName: eshop-aks
pathBase: /webmarketingapigw
image:
repository: eshop/ocelotapigw
tag: latest
pullPolicy: IfNotPresent
repository: envoyproxy/envoy
tag: v1.11.1
service:
type: ClusterIP
@ -26,41 +25,7 @@ tolerations: []
affinity: {}
# env defines the environment variables that will be declared in the pod
env:
urls:
# configmap declares variables which value is taken from the config map defined in template configmap.yaml (name is name of var and key the key in configmap).
configmap:
- name: IdentityUrl
key: internalurls__identity
- name: CatalogUrlHC
key: internalurls__catalog__hc
- name: BasketUrlHC
key: internalurls__basket__hc
- name: IdentityUrlHC
key: internalurls__identity__hc
- name: OrderingUrlHC
key: internalurls__ordering__hc
- name: MarketingUrlHC
key: internalurls__marketing__hc
- name: PaymentUrlHC
key: internalurls__payment__hc
- name: LocationUrlHC
key: internalurls__location__hc
# values define environment variables with a fixed value (no configmap involved) (name is name of var, and value is its value)
values:
- name: ASPNETCORE_ENVIRONMENT
value: Development
probes:
liveness:
path: /liveness
initialDelaySeconds: 10
periodSeconds: 15
port: 80
readiness:
path: /hc
timeoutSeconds: 5
initialDelaySeconds: 90
periodSeconds: 60
port: 80
ocelot:
configPath: /app/configuration
env: {}
envoy:
configPath: /etc/envoy

+ 0
- 166
k8s/helm/apigwws/configuration-web-shopping.json View File

@ -1,166 +0,0 @@
{
"ReRoutes": [
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "catalog",
"Port": 5000
}
],
"UpstreamPathTemplate": "/api/{version}/c/{everything}",
"UpstreamHttpMethod": [ "GET" ]
},
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "catalog",
"Port": 80
}
],
"UpstreamPathTemplate": "/grpc/{version}/c/{everything}",
"UpstreamHttpMethod": [ "GET" ]
},
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "basket",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/b/{everything}",
"UpstreamHttpMethod": [],
"AuthenticationOptions": {
"AuthenticationProviderKey": "IdentityApiKey",
"AllowedScopes": []
}
},
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "ordering",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/o/{everything}",
"UpstreamHttpMethod": [],
"AuthenticationOptions": {
"AuthenticationProviderKey": "IdentityApiKey",
"AllowedScopes": []
}
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "webshoppingagg",
"Port": 80
}
],
"UpstreamPathTemplate": "/{everything}",
"UpstreamHttpMethod": [ "POST", "PUT", "GET" ],
"AuthenticationOptions": {
"AuthenticationProviderKey": "IdentityApiKey",
"AllowedScopes": []
}
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "ordering",
"Port": 80
}
],
"UpstreamPathTemplate": "/orders-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "ordering-signalrhub",
"Port": 80
}
],
"UpstreamPathTemplate": "/hub/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "basket",
"Port": 80
}
],
"UpstreamPathTemplate": "/basket-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "catalog",
"Port": 5000
}
],
"UpstreamPathTemplate": "/catalog-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "marketing",
"Port": 80
}
],
"UpstreamPathTemplate": "/marketing-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "payment",
"Port": 80
}
],
"UpstreamPathTemplate": "/payment-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "locations.api",
"Port": 80
}
],
"UpstreamPathTemplate": "/location-api/{everything}",
"UpstreamHttpMethod": []
}
],
"GlobalConfiguration": {
"RequestIdKey": "OcRequestId",
"AdministrationPath": "/administration"
}
}

+ 80
- 0
k8s/helm/apigwws/envoy.yaml View File

@ -0,0 +1,80 @@
admin:
access_log_path: "/dev/null"
address:
socket_address:
address: 0.0.0.0
port_value: 8001
static_resources:
listeners:
- address:
socket_address:
address: 0.0.0.0
port_value: 80
filter_chains:
- filters:
- name: envoy.http_connection_manager
config:
codec_type: auto
stat_prefix: ingress_http
route_config:
name: eshop_backend_route
virtual_hosts:
- name: eshop_backend
domains:
- "*"
routes:
- match:
prefix: "/api/v1/c/"
route:
prefix_rewrite: "/api/v1/"
cluster: catalog
- match:
prefix: "/api/v1/o/"
route:
prefix_rewrite: "/api/v1/"
cluster: ordering
- match:
prefix: "/api/v1/b/"
route:
prefix_rewrite: "/api/v1/"
cluster: basket
- match:
prefix: "/"
route:
prefix_rewrite: "/"
cluster: shoppingagg
http_filters:
- name: envoy.router
clusters:
- name: shoppingagg
connect_timeout: 0.25s
type: logical_dns
lb_policy: round_robin
hosts:
- socket_address:
address: webshoppingagg
port_value: 80
- name: catalog
connect_timeout: 0.25s
type: logical_dns
lb_policy: round_robin
hosts:
- socket_address:
address: catalog-api
port_value: 80
- name: basket
connect_timeout: 0.25s
type: logical_dns
lb_policy: round_robin
hosts:
- socket_address:
address: basket-api
port_value: 80
- name: ordering
connect_timeout: 0.25s
type: logical_dns
lb_policy: round_robin
hosts:
- socket_address:
address: ordering-api
port_value: 80

+ 0
- 21
k8s/helm/apigwws/templates/configmap.yaml View File

@ -1,21 +0,0 @@
{{- $name := include "apigwws.fullname" . -}}
apiVersion: v1
kind: ConfigMap
metadata:
name: "cfg-{{ $name }}"
labels:
app: {{ template "apigwws.name" . }}
chart: {{ template "apigwws.chart" .}}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
data:
internalurls__identity: http://{{ .Values.app.svc.identity }}
internalurls__basket__hc: http://{{ .Values.app.svc.basket }}/hc
internalurls__catalog__hc: http://{{ .Values.app.svc.catalog }}/hc
internalurls__identity__hc: http://{{ .Values.app.svc.identity }}/hc
internalurls__ordering__hc: http://{{ .Values.app.svc.ordering }}/hc
internalurls__marketing__hc: http://{{ .Values.app.svc.marketing }}/hc
internalurls__payment__hc: http://{{ .Values.app.svc.payment }}/hc
internalurls__location__hc: http://{{ .Values.app.svc.locations }}/hc

+ 5
- 5
k8s/helm/apigwws/templates/deployment.yaml View File

@ -1,6 +1,6 @@
{{- $name := include "apigwws.fullname" . -}}
{{- $cfgname := printf "%s-%s" "cfg" $name -}}
{{- $ocelotcfgname := printf "%s-%s" "ocelot" $name -}}
{{- $envoycfgname := printf "%s-%s" "envoy" $name -}}
apiVersion: apps/v1beta2
kind: Deployment
metadata:
@ -29,10 +29,10 @@ spec:
volumes:
- name: config
configMap:
name: {{ $ocelotcfgname }}
name: {{ $envoycfgname }}
items:
- key: configuration-web-shopping.json
path: configuration.json
- key: envoy.yaml
path: envoy.yaml
containers:
- name: {{ .Chart.Name }}
{{ if .Values.probes -}}
@ -60,7 +60,7 @@ spec:
imagePullPolicy: {{ .Values.image.pullPolicy }}
volumeMounts:
- name: config
mountPath: {{ .Values.ocelot.configPath }}
mountPath: {{ .Values.envoy.configPath }}
env:
- name: PATH_BASE
value: {{ include "pathBase" . }}


k8s/helm/apigwws/templates/ocelot-cm.yaml → k8s/helm/apigwws/templates/envoy-cm.yaml View File

@ -3,12 +3,12 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: "ocelot-{{ $name }}"
name: "envoy-{{ $name }}"
labels:
app: {{ template "apigwws.name" . }}
chart: {{ template "apigwws.chart" .}}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
data:
{{ (.Files.Glob "configuration-web-shopping.json").AsConfig | indent 2 }}
{{ (.Files.Glob "envoy.yaml").AsConfig | indent 2 }}

+ 6
- 41
k8s/helm/apigwws/values.yaml View File

@ -3,9 +3,8 @@ clusterName: eshop-aks
pathBase: /webshoppingapigw
image:
repository: eshop/ocelotapigw
tag: latest
pullPolicy: IfNotPresent
repository: envoyproxy/envoy
tag: v1.11.1
service:
type: ClusterIP
@ -26,41 +25,7 @@ tolerations: []
affinity: {}
# env defines the environment variables that will be declared in the pod
env:
urls:
# configmap declares variables which value is taken from the config map defined in template configmap.yaml (name is name of var and key the key in configmap).
configmap:
- name: IdentityUrl
key: internalurls__identity
- name: CatalogUrlHC
key: internalurls__catalog__hc
- name: BasketUrlHC
key: internalurls__basket__hc
- name: IdentityUrlHC
key: internalurls__identity__hc
- name: OrderingUrlHC
key: internalurls__ordering__hc
- name: MarketingUrlHC
key: internalurls__marketing__hc
- name: PaymentUrlHC
key: internalurls__payment__hc
- name: LocationUrlHC
key: internalurls__location__hc
# values define environment variables with a fixed value (no configmap involved) (name is name of var, and value is its value)
values:
- name: ASPNETCORE_ENVIRONMENT
value: Development
probes:
liveness:
path: /liveness
initialDelaySeconds: 10
periodSeconds: 15
port: 80
readiness:
path: /hc
timeoutSeconds: 5
initialDelaySeconds: 90
periodSeconds: 60
port: 80
ocelot:
configPath: /app/configuration
env: {}
envoy:
configPath: /etc/envoy

+ 10
- 10
k8s/helm/app.yaml View File

@ -25,12 +25,12 @@ app: # app global settings
webhooks: webhooks-api # ingress entry for webhooks api
webhooksweb: webhooks-web # ingress entry for webhooks web demo client
svc:
basket: basket # service name for basket api
catalog: catalog # service name for catalog api
ordering: ordering # service name for ordering api
orderingbackgroundtasks: orderingbackgroundtasks # service name for orderingbackgroundtasks
basket: basket-apo # service name for basket api
catalog: catalog-api # service name for catalog api
ordering: ordering-api # service name for ordering api
orderingbackgroundtasks: ordering-backgroundtasks # service name for orderingbackgroundtasks
orderingsignalrhub: ordering-signalrhub # service name for orderingsignalrhub
identity: identity # service name for identity api
identity: identity-api # service name for identity api
mvc: webmvc # service name for web mvc
spa: webspa # service name for web spa
status: webstatus # service name for web status
@ -40,8 +40,8 @@ app: # app global settings
mobileshoppingapigw: mobileshoppingapigw # service name for mobile shopping Agw
webshoppingagg: webshoppingagg # service name for web shopping aggregator
mobileshoppingagg: mobileshoppingagg # service name for mobile shopping aggregator
payment: payment # service name for payment api
locations: locations # service name for locations api
marketing: marketing # service name for marketing ap
webhooks: webhooks # service name for webhooks api
webhooksweb: webhooksweb # service name for webhooks web
payment: payment-api # service name for payment api
locations: locations-api # service name for locations api
marketing: marketing-api # service name for marketing ap
webhooks: webhooks-api # service name for webhooks api
webhooksweb: webhooks-client # service name for webhooks web

+ 4
- 0
k8s/helm/basket-api/templates/deployment.yaml View File

@ -21,6 +21,10 @@ spec:
labels:
app: {{ template "basket-api.name" . }}
release: {{ .Release.Name }}
{{ if .Values.inf.mesh.enabled -}}
annotations:
linkerd.io/inject: enabled
{{- end }}
spec:
{{ if .Values.inf.registry -}}
imagePullSecrets:


+ 4
- 19
k8s/helm/catalog-api/templates/deployment.yaml View File

@ -21,6 +21,10 @@ spec:
labels:
app: {{ template "catalog-api.name" . }}
release: {{ .Release.Name }}
{{ if .Values.inf.mesh.enabled -}}
annotations:
linkerd.io/inject: enabled
{{- end }}
spec:
{{ if .Values.inf.registry -}}
imagePullSecrets:
@ -80,16 +84,6 @@ spec:
protocol: TCP
resources:
{{ toYaml .Values.resources | indent 12 }}
- name: envoy-proxy
image: envoyproxy/envoy
imagePullPolicy: IfNotPresent
ports:
- name: envoy
containerPort: 51051
protocol: TCP
volumeMounts:
- name: envoy-config
mountPath: /etc/envoy
{{- with .Values.nodeSelector }}
nodeSelector:
{{ toYaml . | indent 8 }}
@ -102,13 +96,4 @@ spec:
tolerations:
{{ toYaml . | indent 8 }}
{{- end }}
volumes:
- name: envoy-config
configMap:
name: envoy-{{ $name }}
items:
- key: _envoy.yaml
path: envoy.yaml
- key: _catalog.proto-descriptor.pb
path: catalog.proto-descriptor.pb

+ 1
- 1
k8s/helm/catalog-api/templates/service.yaml View File

@ -14,7 +14,7 @@ spec:
targetPort: http
protocol: TCP
name: http
- port: {{ .Values.service.grpc }}
- port: {{ .Values.service.grpcPort }}
targetPort: grpc
protocol: TCP
name: grpc


+ 22
- 9
k8s/helm/deploy-all.ps1 View File

@ -10,7 +10,10 @@ Param(
[parameter(Mandatory=$false)][string]$aksName="",
[parameter(Mandatory=$false)][string]$aksRg="",
[parameter(Mandatory=$false)][string]$imageTag="latest",
[parameter(Mandatory=$false)][bool]$useLocalk8s=$false
[parameter(Mandatory=$false)][bool]$useLocalk8s=$false,
[parameter(Mandatory=$false)][bool]$useMesh=$true,
[parameter(Mandatory=$false)][string][ValidateSet('Always','IfNotPresent','Never', IgnoreCase=$false)]$imagePullPolicy="Always",
[parameter(Mandatory=$false)][string]$chartsToDeploy="*"
)
$dns = $externalDns
@ -62,7 +65,8 @@ if (-not [string]::IsNullOrEmpty($registry)) {
Write-Host "Begin eShopOnContainers installation using Helm" -ForegroundColor Green
$infras = ("sql-data", "nosql-data", "rabbitmq", "keystore-data", "basket-data")
$charts = ("eshop-common", "apigwmm", "apigwms", "apigwwm", "apigwws", "basket-api","catalog-api", "identity-api", "locations-api", "marketing-api", "mobileshoppingagg","ordering-api","ordering-backgroundtasks","ordering-signalrhub", "payment-api", "webmvc", "webshoppingagg", "webspa", "webstatus", "webhooks-api", "webhooks-web")
$charts = ("eshop-common", "basket-api","catalog-api", "identity-api", "locations-api", "marketing-api", "mobileshoppingagg","ordering-api","ordering-backgroundtasks","ordering-signalrhub", "payment-api", "webmvc", "webshoppingagg", "webspa", "webstatus", "webhooks-api", "webhooks-web")
$gateways = ("apigwmm", "apigwms", "apigwwm", "apigwws")
if ($deployInfrastructure) {
foreach ($infra in $infras) {
@ -76,16 +80,25 @@ else {
if ($deployCharts) {
foreach ($chart in $charts) {
Write-Host "Installing: $chart" -ForegroundColor Green
if ($useCustomRegistry) {
helm install --set inf.registry.server=$registry --set inf.registry.login=$dockerUser --set inf.registry.pwd=$dockerPassword --set inf.registry.secretName=eshop-docker-scret --values app.yaml --values inf.yaml --values $ingressValuesFile --set app.name=$appName --set inf.k8s.dns=$dns --set "ingress.hosts={$dns}" --set image.tag=$imageTag --set image.pullPolicy=Always --name="$appName-$chart" $chart
}
else {
if ($chart -ne "eshop-common") { # eshop-common is ignored when no secret must be deployed
helm install --values app.yaml --values inf.yaml --values $ingressValuesFile --set app.name=$appName --set inf.k8s.dns=$dns --set "ingress.hosts={$dns}" --set image.tag=$imageTag --set image.pullPolicy=Always --name="$appName-$chart" $chart
if ($chartsToDeploy -eq "*" -or $chartsToDeploy.Contains($chart)) {
Write-Host "Installing: $chart" -ForegroundColor Green
if ($useCustomRegistry) {
helm install --set inf.registry.server=$registry --set inf.registry.login=$dockerUser --set inf.registry.pwd=$dockerPassword --set inf.registry.secretName=eshop-docker-scret --values app.yaml --values inf.yaml --values $ingressValuesFile --set app.name=$appName --set inf.k8s.dns=$dns --set "ingress.hosts={$dns}" --set image.tag=$imageTag --set image.pullPolicy=$imagePullPolicy --set inf.mesh.enabled=$useMesh --name="$appName-$chart" $chart
}
else {
if ($chart -ne "eshop-common") { # eshop-common is ignored when no secret must be deployed
helm install --values app.yaml --values inf.yaml --values $ingressValuesFile --set app.name=$appName --set inf.k8s.dns=$dns --set "ingress.hosts={$dns}" --set image.tag=$imageTag --set image.pullPolicy=$imagePullPolicy --set inf.mesh.enabled=$useMesh --name="$appName-$chart" $chart
}
}
}
}
foreach ($chart in $gateways) {
if ($chartsToDeploy -eq "*" -or $chartsToDeploy.Contains($chart)) {
Write-Host "Installing Api Gateway Chart: $chart" -ForegroundColor Green
helm install --values app.yaml --values inf.yaml --values $ingressValuesFile --set app.name=$appName --set inf.k8s.dns=$dns --set "ingress.hosts={$dns}" --set image.pullPolicy=$imagePullPolicy --set inf.mesh.enabled=$useMesh --name="$appName-$chart" $chart
}
}
}
else {
Write-Host "eShopOnContainers non-infrastructure charts aren't installed (-deployCharts is false)" -ForegroundColor Yellow


+ 4
- 0
k8s/helm/identity-api/templates/deployment.yaml View File

@ -21,6 +21,10 @@ spec:
labels:
app: {{ template "identity-api.name" . }}
release: {{ .Release.Name }}
{{ if .Values.inf.mesh.enabled -}}
annotations:
linkerd.io/inject: enabled
{{- end }}
spec:
{{ if .Values.inf.registry -}}
imagePullSecrets:


+ 2
- 0
k8s/helm/inf.yaml View File

@ -2,6 +2,8 @@
# It is used on all charts, so ** MUST BE INCLUDED ** on every deployment
inf:
mesh:
enabled: true
sql: # inf.sql defines the sql server databases & logins
# host: my-sql-server # Uncomment to specify a custom sql-server to be used. By default "sql-data-<appname>" will be used
common:


+ 4
- 0
k8s/helm/locations-api/templates/deployment.yaml View File

@ -21,6 +21,10 @@ spec:
labels:
app: {{ template "locations-api.name" . }}
release: {{ .Release.Name }}
{{ if .Values.inf.mesh.enabled -}}
annotations:
linkerd.io/inject: enabled
{{- end }}
spec:
{{ if .Values.inf.registry -}}
imagePullSecrets:


+ 4
- 0
k8s/helm/marketing-api/templates/deployment.yaml View File

@ -21,6 +21,10 @@ spec:
labels:
app: {{ template "marketing-api.name" . }}
release: {{ .Release.Name }}
{{ if .Values.inf.mesh.enabled -}}
annotations:
linkerd.io/inject: enabled
{{- end }}
spec:
{{ if .Values.inf.registry -}}
imagePullSecrets:


+ 4
- 0
k8s/helm/mobileshoppingagg/templates/deployment.yaml View File

@ -21,6 +21,10 @@ spec:
labels:
app: {{ template "mobileshoppingagg.name" . }}
release: {{ .Release.Name }}
{{ if .Values.inf.mesh.enabled -}}
annotations:
linkerd.io/inject: enabled
{{- end }}
spec:
{{ if .Values.inf.registry -}}
imagePullSecrets:


+ 4
- 0
k8s/helm/ordering-api/templates/deployment.yaml View File

@ -21,6 +21,10 @@ spec:
labels:
app: {{ template "ordering-api.name" . }}
release: {{ .Release.Name }}
{{ if .Values.inf.mesh.enabled -}}
annotations:
linkerd.io/inject: enabled
{{- end }}
spec:
{{ if .Values.inf.registry -}}
imagePullSecrets:


+ 1
- 1
k8s/helm/ordering-api/templates/service.yaml View File

@ -14,7 +14,7 @@ spec:
targetPort: http
protocol: TCP
name: http
- port: {{ .Values.service.grpcPort }}}
- port: {{ .Values.service.grpcPort }}
targetPort: grpc
protocol: TCP
name: grpc


+ 4
- 0
k8s/helm/payment-api/templates/deployment.yaml View File

@ -21,6 +21,10 @@ spec:
labels:
app: {{ template "payment-api.name" . }}
release: {{ .Release.Name }}
{{ if .Values.inf.mesh.enabled -}}
annotations:
linkerd.io/inject: enabled
{{- end }}
spec:
{{ if .Values.inf.registry -}}
imagePullSecrets:


+ 4
- 0
k8s/helm/webhooks-api/templates/deployment.yaml View File

@ -21,6 +21,10 @@ spec:
labels:
app: {{ template "webhooks-api.name" . }}
release: {{ .Release.Name }}
{{ if .Values.inf.mesh.enabled -}}
annotations:
linkerd.io/inject: enabled
{{- end }}
spec:
{{ if .Values.inf.registry -}}
imagePullSecrets:


+ 4
- 0
k8s/helm/webhooks-web/templates/deployment.yaml View File

@ -21,6 +21,10 @@ spec:
labels:
app: {{ template "webhooks-web.name" . }}
release: {{ .Release.Name }}
{{ if .Values.inf.mesh.enabled -}}
annotations:
linkerd.io/inject: enabled
{{- end }}
spec:
{{ if .Values.inf.registry -}}
imagePullSecrets:


+ 4
- 0
k8s/helm/webmvc/templates/deployment.yaml View File

@ -21,6 +21,10 @@ spec:
labels:
app: {{ template "webmvc.name" . }}
release: {{ .Release.Name }}
{{ if .Values.inf.mesh.enabled -}}
annotations:
linkerd.io/inject: enabled
{{- end }}
spec:
{{ if .Values.inf.registry -}}
imagePullSecrets:


+ 4
- 0
k8s/helm/webstatus/templates/deployment.yaml View File

@ -21,6 +21,10 @@ spec:
labels:
app: {{ template "webstatus.name" . }}
release: {{ .Release.Name }}
{{ if .Values.inf.mesh.enabled -}}
annotations:
linkerd.io/inject: enabled
{{- end }}
spec:
{{ if .Values.inf.registry -}}
imagePullSecrets:


+ 0
- 34
k8s/ocelot/configuration-mobile-marketing.json View File

@ -1,34 +0,0 @@
{
"ReRoutes": [
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "marketing",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/m/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "locations",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/l/{everything}",
"UpstreamHttpMethod": []
}
],
"GlobalConfiguration": {
"RequestIdKey": "OcRequestId",
"AdministrationPath": "/administration"
}
}

+ 0
- 142
k8s/ocelot/configuration-mobile-shopping.json View File

@ -1,142 +0,0 @@
{
"ReRoutes": [
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "catalog",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/c/{everything}",
"UpstreamHttpMethod": [ "GET" ]
},
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "basket",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/b/{everything}",
"UpstreamHttpMethod": [],
"AuthenticationOptions": {
"AuthenticationProviderKey": "IdentityApiKey",
"AllowedScopes": []
}
},
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "ordering",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/o/{everything}",
"UpstreamHttpMethod": [],
"AuthenticationOptions": {
"AuthenticationProviderKey": "IdentityApiKey",
"AllowedScopes": []
}
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "mobileshoppingagg",
"Port": 80
}
],
"UpstreamPathTemplate": "/{everything}",
"UpstreamHttpMethod": [ "POST", "PUT", "GET" ],
"AuthenticationOptions": {
"AuthenticationProviderKey": "IdentityApiKey",
"AllowedScopes": []
}
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "ordering",
"Port": 80
}
],
"UpstreamPathTemplate": "/orders-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "basket",
"Port": 80
}
],
"UpstreamPathTemplate": "/basket-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "catalog",
"Port": 80
}
],
"UpstreamPathTemplate": "/catalog-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "marketing",
"Port": 80
}
],
"UpstreamPathTemplate": "/marketing-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "payment",
"Port": 80
}
],
"UpstreamPathTemplate": "/payment-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "locations.api",
"Port": 80
}
],
"UpstreamPathTemplate": "/location-api/{everything}",
"UpstreamHttpMethod": []
}
],
"GlobalConfiguration": {
"RequestIdKey": "OcRequestId",
"AdministrationPath": "/administration"
}
}

+ 0
- 34
k8s/ocelot/configuration-web-marketing.json View File

@ -1,34 +0,0 @@
{
"ReRoutes": [
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "marketing",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/m/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "locations",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/l/{everything}",
"UpstreamHttpMethod": []
}
],
"GlobalConfiguration": {
"RequestIdKey": "OcRequestId",
"AdministrationPath": "/administration"
}
}

+ 0
- 154
k8s/ocelot/configuration-web-shopping.json View File

@ -1,154 +0,0 @@
{
"ReRoutes": [
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "catalog",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/c/{everything}",
"UpstreamHttpMethod": [ "GET" ]
},
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "basket",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/b/{everything}",
"UpstreamHttpMethod": [],
"AuthenticationOptions": {
"AuthenticationProviderKey": "IdentityApiKey",
"AllowedScopes": []
}
},
{
"DownstreamPathTemplate": "/api/{version}/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "ordering",
"Port": 80
}
],
"UpstreamPathTemplate": "/api/{version}/o/{everything}",
"UpstreamHttpMethod": [],
"AuthenticationOptions": {
"AuthenticationProviderKey": "IdentityApiKey",
"AllowedScopes": []
}
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "webshoppingagg",
"Port": 80
}
],
"UpstreamPathTemplate": "/{everything}",
"UpstreamHttpMethod": [ "POST", "PUT", "GET" ],
"AuthenticationOptions": {
"AuthenticationProviderKey": "IdentityApiKey",
"AllowedScopes": []
}
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "ordering",
"Port": 80
}
],
"UpstreamPathTemplate": "/orders-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "ordering-signalrhub",
"Port": 80
}
],
"UpstreamPathTemplate": "/hub/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "basket",
"Port": 80
}
],
"UpstreamPathTemplate": "/basket-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "catalog",
"Port": 80
}
],
"UpstreamPathTemplate": "/catalog-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "marketing",
"Port": 80
}
],
"UpstreamPathTemplate": "/marketing-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "payment",
"Port": 80
}
],
"UpstreamPathTemplate": "/payment-api/{everything}",
"UpstreamHttpMethod": []
},
{
"DownstreamPathTemplate": "/{everything}",
"DownstreamScheme": "http",
"DownstreamHostAndPorts": [
{
"Host": "locations.api",
"Port": 80
}
],
"UpstreamPathTemplate": "/location-api/{everything}",
"UpstreamHttpMethod": []
}
],
"GlobalConfiguration": {
"RequestIdKey": "OcRequestId",
"AdministrationPath": "/administration"
}
}

+ 0
- 155
k8s/ocelot/deployment.yaml View File

@ -1,155 +0,0 @@
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: apigwmm
spec:
paused: true
template:
metadata:
labels:
app: eshop
component: apigwmm
spec:
containers:
- name: apigwmm
image: eshop/ocelotapigw
imagePullPolicy: Always
env:
- name: PATH_BASE
value: /mobilemarketingapigw
- name: IdentityUrl
valueFrom:
configMapKeyRef:
name: internalurls
key: identity
ports:
- containerPort: 80
volumeMounts:
- name: config
mountPath: /app/configuration
volumes:
- name: config
configMap:
name: ocelot
items:
- key: mm
path: configuration.json
imagePullSecrets:
- name: registry-key
---
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: apigwms
spec:
paused: true
template:
metadata:
labels:
app: eshop
component: apigwms
spec:
containers:
- name: apigwms
image: eshop/ocelotapigw
imagePullPolicy: Always
env:
- name: PATH_BASE
value: /mobileshoppingapigw
- name: IdentityUrl
valueFrom:
configMapKeyRef:
name: internalurls
key: identity
ports:
- containerPort: 80
volumeMounts:
- name: config
mountPath: /app/configuration
volumes:
- name: config
configMap:
name: ocelot
items:
- key: ms
path: configuration.json
imagePullSecrets:
- name: registry-key
---
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: apigwwm
spec:
paused: true
template:
metadata:
labels:
app: eshop
component: apigwwm
spec:
containers:
- name: apigwwm
image: eshop/ocelotapigw
imagePullPolicy: Always
env:
- name: PATH_BASE
value: /webmarketingapigw
- name: IdentityUrl
valueFrom:
configMapKeyRef:
name: internalurls
key: identity
ports:
- containerPort: 80
volumeMounts:
- name: config
mountPath: /app/configuration
volumes:
- name: config
configMap:
name: ocelot
items:
- key: wm
path: configuration.json
imagePullSecrets:
- name: registry-key
---
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: apigwws
spec:
paused: true
template:
metadata:
labels:
app: eshop
component: apigwws
spec:
containers:
- name: apigwws
image: eshop/ocelotapigw
imagePullPolicy: Always
env:
- name: PATH_BASE
value: /webshoppingapigw
- name: IdentityUrl
valueFrom:
configMapKeyRef:
name: internalurls
key: identity
ports:
- containerPort: 80
volumeMounts:
- name: config
mountPath: /app/configuration
volumes:
- name: config
configMap:
name: ocelot
items:
- key: ws
path: configuration.json
imagePullSecrets:
- name: registry-key

+ 0
- 55
k8s/ocelot/service.yaml View File

@ -1,55 +0,0 @@
apiVersion: v1
kind: Service
metadata:
labels:
app: eshop
component: ocelotapigw-mm
name: ocelotapigw-mm
spec:
ports:
- port: 80
selector:
app: eshop
component: apigwmm
---
apiVersion: v1
kind: Service
metadata:
labels:
app: eshop
component: ocelotapigw-ms
name: ocelotapigw-ms
spec:
ports:
- port: 80
selector:
app: eshop
component: apigwms
---
apiVersion: v1
kind: Service
metadata:
labels:
app: eshop
component: ocelotapigw-wm
name: ocelotapigw-wm
spec:
ports:
- port: 80
selector:
app: eshop
component: apigwwm
---
apiVersion: v1
kind: Service
metadata:
labels:
app: eshop
component: ocelotapigw-ws
name: ocelotapigw-ws
spec:
ports:
- port: 80
selector:
app: eshop
component: apigwws

+ 0
- 1
src/ApiGateways/Mobile.Bff.Shopping/aggregator/Dockerfile View File

@ -7,7 +7,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/ApiGateways/Web.Bff.Shopping/aggregator/Dockerfile View File

@ -7,7 +7,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/Services/Basket/Basket.API/Dockerfile View File

@ -7,7 +7,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/Services/Catalog/Catalog.API/Dockerfile View File

@ -8,7 +8,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/Services/Identity/Identity.API/Dockerfile View File

@ -7,7 +7,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/Services/Location/Locations.API/Dockerfile View File

@ -7,7 +7,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/Services/Marketing/Marketing.API/Dockerfile View File

@ -7,7 +7,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/Services/Ordering/Ordering.API/Dockerfile View File

@ -7,7 +7,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/Services/Ordering/Ordering.BackgroundTasks/Dockerfile View File

@ -7,7 +7,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/Services/Ordering/Ordering.SignalrHub/Dockerfile View File

@ -7,7 +7,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/Services/Payment/Payment.API/Dockerfile View File

@ -7,7 +7,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/Services/Webhooks/Webhooks.API/Dockerfile View File

@ -7,7 +7,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/Web/WebMVC/Dockerfile View File

@ -7,7 +7,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/Web/WebSPA/Dockerfile View File

@ -16,7 +16,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/Web/WebStatus/Dockerfile View File

@ -7,7 +7,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 0
- 1
src/Web/WebhookClient/Dockerfile View File

@ -8,7 +8,6 @@ WORKDIR /src
COPY scripts scripts/
COPY ApiGateways/*/*.csproj csproj-files/
COPY ApiGateways/*/*/*.csproj csproj-files/
COPY BuildingBlocks/*/*/*.csproj csproj-files/
COPY Services/*/*/*.csproj csproj-files/


+ 2
- 26
src/docker-compose.yml View File

@ -99,34 +99,10 @@ services:
- sqldata
mobileshoppingapigw:
image: ${REGISTRY:-eshop}/ocelotapigw:${PLATFORM:-linux}-${TAG:-latest}
build:
context: .
dockerfile: ApiGateways/ApiGw-Base/Dockerfile
depends_on:
- nosqldata
- sqldata
- identity-api
- rabbitmq
- ordering-api
- marketing-api
- catalog-api
- basket-api
image: envoyproxy/envoy:v1.11.1
mobilemarketingapigw:
image: ${REGISTRY:-eshop}/ocelotapigw:${PLATFORM:-linux}-${TAG:-latest}
build:
context: .
dockerfile: ApiGateways/ApiGw-Base/Dockerfile
depends_on:
- nosqldata
- sqldata
- identity-api
- rabbitmq
- ordering-api
- marketing-api
- catalog-api
- basket-api
image: envoyproxy/envoy:v1.11.1
mobileshoppingagg:
image: ${REGISTRY:-eshop}/mobileshoppingagg:${PLATFORM:-linux}-${TAG:-latest}


Loading…
Cancel
Save