diff --git a/build/azure-devops/apigws/azure-pipelines.yml b/build/azure-devops/apigws/azure-pipelines.yml index 857355673..e0dacc800 100644 --- a/build/azure-devops/apigws/azure-pipelines.yml +++ b/build/azure-devops/apigws/azure-pipelines.yml @@ -1,5 +1,3 @@ -variables: - registryEndpoint: eshop-registry trigger: branches: include: @@ -8,22 +6,24 @@ trigger: paths: include: - src/ApiGateways/* - - k8s/helm/apigwmm/* - - k8s/helm/apigwms/* - - k8s/helm/apigwwm/* - - k8s/helm/apigwws/* + - deploy/k8s/helm/apigwmm/* + - deploy/k8s/helm/apigwms/* + - deploy/k8s/helm/apigwwm/* + - deploy/k8s/helm/apigwws/* exclude: - src/ApiGateways/Mobile.Bff.Shopping/aggregator/* - src/ApiGateways/Web.Bff.Shopping/aggregator/* jobs: -- template: ../buildimages.yaml - parameters: - services: mobileshoppingapigw mobilemarketingapigw webshoppingapigw webmarketingapigw - registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm -- template: ../multiarch.yaml - parameters: - image: ocelotapigw - branch: $(Build.SourceBranchName) - registryEndpoint: $(registryEndpoint) +- job: PublishCharts + condition: ne('$(Build.Reason)', 'PullRequest') + pool: + vmImage: 'ubuntu-16.04' + steps: + - task: CopyFiles@2 + inputs: + sourceFolder: $(Build.SourcesDirectory)/deploy/k8s/helm + targetFolder: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm + - task: PublishBuildArtifacts@1 + inputs: + pathtoPublish: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm + artifactName: helm diff --git a/build/azure-devops/basket-api/azure-pipelines.yml b/build/azure-devops/basket-api/azure-pipelines.yml index 730680ad9..399b682ec 100644 --- a/build/azure-devops/basket-api/azure-pipelines.yml +++ b/build/azure-devops/basket-api/azure-pipelines.yml @@ -9,14 +9,14 @@ trigger: include: - src/BuildingBlocks/* - src/Services/Basket/* - - k8s/helm/basket-api/* + - deploy/k8s/helm/basket-api/* jobs: - template: ../buildimages.yaml parameters: services: basket.api registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm + helmfrom: $(Build.SourcesDirectory)/deploy/k8s/helm + helmto: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - template: ../multiarch.yaml parameters: image: basket.api diff --git a/build/azure-devops/buildimages.yaml b/build/azure-devops/buildimages.yaml index cf6457513..bdd326de1 100644 --- a/build/azure-devops/buildimages.yaml +++ b/build/azure-devops/buildimages.yaml @@ -13,16 +13,17 @@ jobs: - bash: docker-compose build ${{ parameters.services }} displayName: Create multiarch manifest env: - TAG: ${{ variables['Build.SourceBranchName'] }} + TAG: ${{ variables['Build.SourceBranchName'] }} - job: BuildContainersForPR_Windows - condition: eq('${{ variables['Build.Reason'] }}', 'PullRequest') + condition: False + # condition: eq('${{ variables['Build.Reason'] }}', 'PullRequest') pool: vmImage: 'windows-2019' steps: - bash: docker-compose build ${{ parameters.services }} displayName: Create multiarch manifest env: - TAG: ${{ variables['Build.SourceBranchName'] }} + TAG: ${{ variables['Build.SourceBranchName'] }} PLATFORM: win NODE_IMAGE: stefanscherer/node-windows:10 - job: BuildLinux @@ -51,7 +52,7 @@ jobs: qualifyImageNames: true projectName: "" dockerComposeFileArgs: | - TAG=${{ variables['Build.SourceBranchName'] }} + TAG=${{ variables['Build.SourceBranchName'] }} - task: CopyFiles@2 inputs: sourceFolder: ${{ parameters.helmfrom }} @@ -61,7 +62,8 @@ jobs: pathtoPublish: ${{ parameters.helmto }} artifactName: helm - job: BuildWindows - condition: ne('${{ variables['Build.Reason'] }}', 'PullRequest') + condition: False + # condition: ne('${{ variables['Build.Reason'] }}', 'PullRequest') pool: vmImage: 'windows-2019' steps: @@ -89,4 +91,4 @@ jobs: projectName: "" dockerComposeFileArgs: | TAG=${{ variables['Build.SourceBranchName'] }} - PLATFORM=win + PLATFORM=win diff --git a/build/azure-devops/catalog-api/azure-pipelines.yml b/build/azure-devops/catalog-api/azure-pipelines.yml index 032d1dd2f..a9ae16e39 100644 --- a/build/azure-devops/catalog-api/azure-pipelines.yml +++ b/build/azure-devops/catalog-api/azure-pipelines.yml @@ -9,14 +9,14 @@ trigger: include: - src/BuildingBlocks/* - src/Services/Catalog/* - - k8s/helm/catalog-api/* + - deploy/k8s/helm/catalog-api/* jobs: - template: ../buildimages.yaml parameters: services: catalog.api registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm + helmfrom: $(Build.SourcesDirectory)/deploy/k8s/helm + helmto: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - template: ../multiarch.yaml parameters: image: catalog.api diff --git a/build/azure-devops/identity-api/azure-pipelines.yml b/build/azure-devops/identity-api/azure-pipelines.yml index 07891f32b..a3074e526 100644 --- a/build/azure-devops/identity-api/azure-pipelines.yml +++ b/build/azure-devops/identity-api/azure-pipelines.yml @@ -9,14 +9,14 @@ trigger: include: - src/BuildingBlocks/* - src/Services/Identity/* - - k8s/helm/identity-api/* + - deploy/k8s/helm/identity-api/* jobs: - template: ../buildimages.yaml parameters: services: identity.api registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm + helmfrom: $(Build.SourcesDirectory)/deploy/k8s/helm + helmto: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - template: ../multiarch.yaml parameters: image: identity.api diff --git a/build/azure-devops/infrastructure/azure-pipelines.yml b/build/azure-devops/infrastructure/azure-pipelines.yml index 50296d457..444c84c1f 100644 --- a/build/azure-devops/infrastructure/azure-pipelines.yml +++ b/build/azure-devops/infrastructure/azure-pipelines.yml @@ -9,17 +9,17 @@ trigger: - dev paths: include: - - k8s/helm/basket-data/* - - k8s/helm/keystore-data/* - - k8s/helm/nosql-data/* - - k8s/helm/rabbitmq/* - - k8s/helm/sql-data/* + - deploy/k8s/helm/basket-data/* + - deploy/k8s/helm/keystore-data/* + - deploy/k8s/helm/nosql-data/* + - deploy/k8s/helm/rabbitmq/* + - deploy/k8s/helm/sql-data/* steps: - task: CopyFiles@2 inputs: - sourceFolder: $(Build.SourcesDirectory)/k8s/helm - targetFolder: $(Build.ArtifactStagingDirectory)/k8s/helm + sourceFolder: $(Build.SourcesDirectory)/deploy/k8s/helm + targetFolder: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - task: PublishBuildArtifacts@1 inputs: - pathtoPublish: $(Build.ArtifactStagingDirectory)/k8s/helm + pathtoPublish: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm artifactName: helm diff --git a/build/azure-devops/location-api/azure-pipelines.yml b/build/azure-devops/location-api/azure-pipelines.yml index c926d71ac..33653811b 100644 --- a/build/azure-devops/location-api/azure-pipelines.yml +++ b/build/azure-devops/location-api/azure-pipelines.yml @@ -9,14 +9,14 @@ trigger: include: - src/BuildingBlocks/* - src/Services/Location/* - - k8s/helm/locations-api/* + - deploy/k8s/helm/locations-api/* jobs: - template: ../buildimages.yaml parameters: services: locations.api registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm + helmfrom: $(Build.SourcesDirectory)/deploy/k8s/helm + helmto: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - template: ../multiarch.yaml parameters: image: locations.api diff --git a/build/azure-devops/marketing-api/azure-pipelines.yml b/build/azure-devops/marketing-api/azure-pipelines.yml index c215ecb90..ed1fcae37 100644 --- a/build/azure-devops/marketing-api/azure-pipelines.yml +++ b/build/azure-devops/marketing-api/azure-pipelines.yml @@ -9,14 +9,14 @@ trigger: include: - src/BuildingBlocks/* - src/Services/Marketing/* - - k8s/helm/marketing-api/* + - deploy/k8s/helm/marketing-api/* jobs: - template: ../buildimages.yaml parameters: services: marketing.api registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm + helmfrom: $(Build.SourcesDirectory)/deploy/k8s/helm + helmto: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - template: ../multiarch.yaml parameters: image: marketing.api diff --git a/build/azure-devops/mobile-shopping-agg/azure-pipelines.yml b/build/azure-devops/mobile-shopping-agg/azure-pipelines.yml index 749a589b2..a66c602c2 100644 --- a/build/azure-devops/mobile-shopping-agg/azure-pipelines.yml +++ b/build/azure-devops/mobile-shopping-agg/azure-pipelines.yml @@ -8,14 +8,14 @@ trigger: paths: include: - src/ApiGateways/Mobile.Bff.Shopping/aggregator/* - - k8s/helm/mobileshoppingagg/* + - deploy/k8s/helm/mobileshoppingagg/* jobs: - template: ../buildimages.yaml parameters: services: mobileshoppingagg registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm + helmfrom: $(Build.SourcesDirectory)/deploy/k8s/helm + helmto: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - template: ../multiarch.yaml parameters: image: mobileshoppingagg diff --git a/build/azure-devops/ordering-api/azure-pipelines.yml b/build/azure-devops/ordering-api/azure-pipelines.yml index 4d688c7dc..fe0712c1e 100644 --- a/build/azure-devops/ordering-api/azure-pipelines.yml +++ b/build/azure-devops/ordering-api/azure-pipelines.yml @@ -9,16 +9,16 @@ trigger: include: - src/BuildingBlocks/* - src/Services/Ordering/* - - k8s/helm/ordering-api/* - - k8s/helm/ordering-backgroundtasks/* - - k8s/helm/ordering-signalrhub/* + - deploy/k8s/helm/ordering-api/* + - deploy/k8s/helm/ordering-backgroundtasks/* + - deploy/k8s/helm/ordering-signalrhub/* jobs: - template: ../buildimages.yaml parameters: services: ordering.api registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm + helmfrom: $(Build.SourcesDirectory)/deploy/k8s/helm + helmto: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - template: ../multiarch.yaml parameters: image: ordering.api diff --git a/build/azure-devops/payment-api/azure-pipelines.yml b/build/azure-devops/payment-api/azure-pipelines.yml index 0fed2db92..6be46f3ee 100644 --- a/build/azure-devops/payment-api/azure-pipelines.yml +++ b/build/azure-devops/payment-api/azure-pipelines.yml @@ -9,14 +9,14 @@ trigger: include: - src/BuildingBlocks/* - src/Services/Payment/* - - k8s/helm/payment-api/* + - deploy/k8s/helm/payment-api/* jobs: - template: ../buildimages.yaml parameters: services: payment.api - registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm + registryEndpoint: $(registryEndpoint) + helmfrom: $(Build.SourcesDirectory)/deploy/k8s/helm + helmto: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - template: ../multiarch.yaml parameters: image: payment.api diff --git a/build/azure-devops/readme.md b/build/azure-devops/readme.md index b7216d4de..03680be34 100644 --- a/build/azure-devops/readme.md +++ b/build/azure-devops/readme.md @@ -1,5 +1,5 @@ -# Azure Devops build definitions +# Azure DevOps build definitions -This folder contains the Azure Devops build definitions in YAML format. Each folder contains one `azure-pipelines.yml` that contains the build definition for one microservice (usually a Docker image, but some microservices generates more than one Docker image). +This folder contains the Azure DevOps build definitions in YAML format. Each folder contains one `azure-pipelines.yml` that contains the build definition for one microservice (usually a Docker image, but some microservices generates more than one Docker image). -For more information about YAML builds read the [Azure DevOps documentation](https://docs.microsoft.com/en-us/azure/devops/pipelines/get-started-yaml?view=azure-devops). \ No newline at end of file +For more information about YAML builds read the [Azure DevOps documentation](https://docs.microsoft.com/azure/devops/pipelines/get-started-yaml?view=azure-devops). \ No newline at end of file diff --git a/build/azure-devops/web-shopping-agg/azure-pipelines.yml b/build/azure-devops/web-shopping-agg/azure-pipelines.yml index 9e907d2ce..e112390c0 100644 --- a/build/azure-devops/web-shopping-agg/azure-pipelines.yml +++ b/build/azure-devops/web-shopping-agg/azure-pipelines.yml @@ -8,14 +8,14 @@ trigger: paths: include: - src/ApiGateways/Web.Bff.Shopping/aggregator/* - - k8s/helm/webshoppingagg/* + - deploy/k8s/helm/webshoppingagg/* jobs: - template: ../buildimages.yaml parameters: services: webshoppingagg - registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm + registryEndpoint: $(registryEndpoint) + helmfrom: $(Build.SourcesDirectory)/deploy/k8s/helm + helmto: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - template: ../multiarch.yaml parameters: image: webshoppingagg diff --git a/build/azure-devops/webhooks-api/azure-pipelines.yml b/build/azure-devops/webhooks-api/azure-pipelines.yml index d7fc14ef6..8a8f7818f 100644 --- a/build/azure-devops/webhooks-api/azure-pipelines.yml +++ b/build/azure-devops/webhooks-api/azure-pipelines.yml @@ -9,14 +9,14 @@ trigger: include: - src/BuildingBlocks/* - src/Services/Webhooks/* - - k8s/helm/webhooks-api/* + - deploy/k8s/helm/webhooks-api/* jobs: - template: ../buildimages.yaml parameters: services: webhooks.api - registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm + registryEndpoint: $(registryEndpoint) + helmfrom: $(Build.SourcesDirectory)/deploy/k8s/helm + helmto: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - template: ../multiarch.yaml parameters: image: webhooks.api diff --git a/build/azure-devops/webhooks-client/azure-pipelines.yml b/build/azure-devops/webhooks-client/azure-pipelines.yml index 76b3b63c9..ace77d5a0 100644 --- a/build/azure-devops/webhooks-client/azure-pipelines.yml +++ b/build/azure-devops/webhooks-client/azure-pipelines.yml @@ -9,14 +9,14 @@ trigger: include: - src/BuildingBlocks/* - src/Web/WebhookClient/* - - k8s/helm/webhooks-web/* + - deploy/k8s/helm/webhooks-web/* jobs: - template: ../buildimages.yaml parameters: services: webhooks.client - registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm + registryEndpoint: $(registryEndpoint) + helmfrom: $(Build.SourcesDirectory)/deploy/k8s/helm + helmto: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - template: ../multiarch.yaml parameters: image: webhooks.client diff --git a/build/azure-devops/webmvc/azure-pipelines.yml b/build/azure-devops/webmvc/azure-pipelines.yml index fd637b260..8067daa7f 100644 --- a/build/azure-devops/webmvc/azure-pipelines.yml +++ b/build/azure-devops/webmvc/azure-pipelines.yml @@ -9,14 +9,14 @@ trigger: include: - src/BuildingBlocks/* - src/Web/WebMVC/* - - k8s/helm/webmvc/* + - deploy/k8s/helm/webmvc/* jobs: - template: ../buildimages.yaml parameters: services: webmvc - registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm + registryEndpoint: $(registryEndpoint) + helmfrom: $(Build.SourcesDirectory)/deploy/k8s/helm + helmto: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - template: ../multiarch.yaml parameters: image: webmvc diff --git a/build/azure-devops/webspa/azure-pipelines.yml b/build/azure-devops/webspa/azure-pipelines.yml index 99d8d2daf..0b635e296 100644 --- a/build/azure-devops/webspa/azure-pipelines.yml +++ b/build/azure-devops/webspa/azure-pipelines.yml @@ -9,14 +9,14 @@ trigger: include: - src/BuildingBlocks/* - src/Web/WebSPA/* - - k8s/helm/webspa/* + - deploy/k8s/helm/webspa/* jobs: - template: ../buildimages.yaml parameters: services: webspa - registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm + registryEndpoint: $(registryEndpoint) + helmfrom: $(Build.SourcesDirectory)/deploy/k8s/helm + helmto: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - template: ../multiarch.yaml parameters: image: webspa diff --git a/build/azure-devops/webstatus/azure-pipelines.yml b/build/azure-devops/webstatus/azure-pipelines.yml index f361370e6..b1871f4ae 100644 --- a/build/azure-devops/webstatus/azure-pipelines.yml +++ b/build/azure-devops/webstatus/azure-pipelines.yml @@ -9,14 +9,14 @@ trigger: include: - src/BuildingBlocks/* - src/Web/WebStatus/* - - k8s/helm/webstatus/* + - deploy/k8s/helm/webstatus/* jobs: - template: ../buildimages.yaml parameters: services: webstatus - registryEndpoint: $(registryEndpoint) - helmfrom: $(Build.SourcesDirectory)/k8s/helm - helmto: $(Build.ArtifactStagingDirectory)/k8s/helm + registryEndpoint: $(registryEndpoint) + helmfrom: $(Build.SourcesDirectory)/deploy/k8s/helm + helmto: $(Build.ArtifactStagingDirectory)/deploy/k8s/helm - template: ../multiarch.yaml parameters: image: webstatus diff --git a/deploy/k8s/dashboard-adminuser.yaml b/deploy/k8s/dashboard-adminuser.yaml new file mode 100644 index 000000000..9f24303cd --- /dev/null +++ b/deploy/k8s/dashboard-adminuser.yaml @@ -0,0 +1,18 @@ +apiVersion: v1 +kind: ServiceAccount +metadata: + name: admin-user + namespace: kubernetes-dashboard +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRoleBinding +metadata: + name: admin-user +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: ClusterRole + name: cluster-admin +subjects: +- kind: ServiceAccount + name: admin-user + namespace: kubernetes-dashboard diff --git a/deploy/k8s/deploy-ingress-dockerlocal.ps1 b/deploy/k8s/deploy-ingress-dockerlocal.ps1 deleted file mode 100644 index 43bf5704d..000000000 --- a/deploy/k8s/deploy-ingress-dockerlocal.ps1 +++ /dev/null @@ -1,2 +0,0 @@ -kubectl apply -f nginx-ingress\cm.yaml -kubectl apply -f nginx-ingress\cloud-generic.yaml diff --git a/deploy/k8s/deploy-ingress.ps1 b/deploy/k8s/deploy-ingress.ps1 deleted file mode 100644 index 594986745..000000000 --- a/deploy/k8s/deploy-ingress.ps1 +++ /dev/null @@ -1,2 +0,0 @@ -# Deploy nginx-ingress core files -kubectl apply -f nginx-ingress\mandatory.yaml diff --git a/deploy/k8s/helm/apigwms/envoy.yaml b/deploy/k8s/helm/apigwms/envoy.yaml index 373806b06..1ae8c45a1 100644 --- a/deploy/k8s/helm/apigwms/envoy.yaml +++ b/deploy/k8s/helm/apigwms/envoy.yaml @@ -42,13 +42,20 @@ static_resources: route: auto_host_rewrite: true prefix_rewrite: "/ordering-api/" - cluster: ordering + cluster: ordering - name: "o-long" match: prefix: "/ordering-api/" route: auto_host_rewrite: true - cluster: ordering + cluster: ordering + - name: "h-long" + match: + prefix: "/hub/notificationhub" + route: + auto_host_rewrite: true + cluster: signalr-hub + timeout: 300s - name: "b-short" match: prefix: "/b/" @@ -61,7 +68,7 @@ static_resources: prefix: "/basket-api/" route: auto_host_rewrite: true - cluster: basket + cluster: basket - name: "agg" match: prefix: "/" @@ -70,25 +77,25 @@ static_resources: prefix_rewrite: "/" cluster: shoppingagg http_filters: - - name: envoy.router + - name: envoy.router access_log: - name: envoy.file_access_log filter: - not_health_check_filter: {} + not_health_check_filter: {} config: json_format: time: "%START_TIME%" protocol: "%PROTOCOL%" duration: "%DURATION%" - request_method: "%REQ(:METHOD)%" - request_host: "%REQ(HOST)%" - path: "%REQ(X-ENVOY-ORIGINAL-PATH?:PATH)%" + request_method: "%REQ(:METHOD)%" + request_host: "%REQ(HOST)%" + path: "%REQ(X-ENVOY-ORIGINAL-PATH?:PATH)%" response_flags: "%RESPONSE_FLAGS%" route_name: "%ROUTE_NAME%" upstream_host: "%UPSTREAM_HOST%" upstream_cluster: "%UPSTREAM_CLUSTER%" - upstream_local_address: "%UPSTREAM_LOCAL_ADDRESS%" - path: "/tmp/access.log" + upstream_local_address: "%UPSTREAM_LOCAL_ADDRESS%" + path: "/tmp/access.log" clusters: - name: shoppingagg connect_timeout: 0.25s @@ -113,7 +120,7 @@ static_resources: hosts: - socket_address: address: basket-api - port_value: 80 + port_value: 80 - name: ordering connect_timeout: 0.25s type: strict_dns @@ -121,4 +128,12 @@ static_resources: hosts: - socket_address: address: ordering-api - port_value: 80 \ No newline at end of file + port_value: 80 + - name: signalr-hub + connect_timeout: 0.25s + type: strict_dns + lb_policy: round_robin + hosts: + - socket_address: + address: ordering-signalrhub + port_value: 80 diff --git a/deploy/k8s/helm/apigwws/envoy.yaml b/deploy/k8s/helm/apigwws/envoy.yaml index 1491f37af..1ae8c45a1 100644 --- a/deploy/k8s/helm/apigwws/envoy.yaml +++ b/deploy/k8s/helm/apigwws/envoy.yaml @@ -42,13 +42,20 @@ static_resources: route: auto_host_rewrite: true prefix_rewrite: "/ordering-api/" - cluster: ordering + cluster: ordering - name: "o-long" match: prefix: "/ordering-api/" route: auto_host_rewrite: true - cluster: ordering + cluster: ordering + - name: "h-long" + match: + prefix: "/hub/notificationhub" + route: + auto_host_rewrite: true + cluster: signalr-hub + timeout: 300s - name: "b-short" match: prefix: "/b/" @@ -61,7 +68,7 @@ static_resources: prefix: "/basket-api/" route: auto_host_rewrite: true - cluster: basket + cluster: basket - name: "agg" match: prefix: "/" @@ -70,7 +77,7 @@ static_resources: prefix_rewrite: "/" cluster: shoppingagg http_filters: - - name: envoy.router + - name: envoy.router access_log: - name: envoy.file_access_log filter: @@ -80,15 +87,15 @@ static_resources: time: "%START_TIME%" protocol: "%PROTOCOL%" duration: "%DURATION%" - request_method: "%REQ(:METHOD)%" - request_host: "%REQ(HOST)%" - path: "%REQ(X-ENVOY-ORIGINAL-PATH?:PATH)%" + request_method: "%REQ(:METHOD)%" + request_host: "%REQ(HOST)%" + path: "%REQ(X-ENVOY-ORIGINAL-PATH?:PATH)%" response_flags: "%RESPONSE_FLAGS%" route_name: "%ROUTE_NAME%" upstream_host: "%UPSTREAM_HOST%" upstream_cluster: "%UPSTREAM_CLUSTER%" upstream_local_address: "%UPSTREAM_LOCAL_ADDRESS%" - path: "/tmp/access.log" + path: "/tmp/access.log" clusters: - name: shoppingagg connect_timeout: 0.25s @@ -113,7 +120,7 @@ static_resources: hosts: - socket_address: address: basket-api - port_value: 80 + port_value: 80 - name: ordering connect_timeout: 0.25s type: strict_dns @@ -121,4 +128,12 @@ static_resources: hosts: - socket_address: address: ordering-api - port_value: 80 \ No newline at end of file + port_value: 80 + - name: signalr-hub + connect_timeout: 0.25s + type: strict_dns + lb_policy: round_robin + hosts: + - socket_address: + address: ordering-signalrhub + port_value: 80 diff --git a/deploy/k8s/helm/webstatus/values.yaml b/deploy/k8s/helm/webstatus/values.yaml index 7d23ce227..e5a23ec85 100644 --- a/deploy/k8s/helm/webstatus/values.yaml +++ b/deploy/k8s/helm/webstatus/values.yaml @@ -55,54 +55,37 @@ env: - name: HealthChecks-UI__HealthChecks__4__Uri key: internalurls__ordering__hc - name: HealthChecks-UI__HealthChecks__5__Name - key: name__orderingbackground__hc + key: name__basket__hc - name: HealthChecks-UI__HealthChecks__5__Uri - key: internalurls__orderingbackground__hc + key: internalurls__basket__hc - name: HealthChecks-UI__HealthChecks__6__Name - key: name__signalrhub__hc + key: name__catalog__hc - name: HealthChecks-UI__HealthChecks__6__Uri - key: internalurls__signalrhub__hc + key: internalurls__catalog__hc - name: HealthChecks-UI__HealthChecks__7__Name - key: name__basket__hc + key: name__identity__hc - name: HealthChecks-UI__HealthChecks__7__Uri - key: internalurls__basket__hc + key: internalurls__identity__hc - name: HealthChecks-UI__HealthChecks__8__Name - key: name__catalog__hc + key: name__marketing__hc - name: HealthChecks-UI__HealthChecks__8__Uri - key: internalurls__catalog__hc + key: internalurls__marketing__hc - name: HealthChecks-UI__HealthChecks__9__Name - key: name__identity__hc + key: name__locations__hc - name: HealthChecks-UI__HealthChecks__9__Uri - key: internalurls__identity__hc + key: internalurls__locations__hc - name: HealthChecks-UI__HealthChecks__10__Name - key: name__marketing__hc + key: name__payment__hc - name: HealthChecks-UI__HealthChecks__10__Uri - key: internalurls__marketing__hc + key: internalurls__payment__hc - name: HealthChecks-UI__HealthChecks__11__Name - key: name__locations__hc + key: name__signalrhub__hc - name: HealthChecks-UI__HealthChecks__11__Uri - key: internalurls__locations__hc + key: internalurls__signalrhub__hc - name: HealthChecks-UI__HealthChecks__12__Name - key: name__payment__hc + key: name__orderingbackground__hc - name: HealthChecks-UI__HealthChecks__12__Uri - key: internalurls__payment__hc - - - name: HealthChecks-UI__HealthChecks__13__Name - key: name__apigwws__hc - - name: HealthChecks-UI__HealthChecks__13__Uri - key: internalurls__apigwws__hc - - name: HealthChecks-UI__HealthChecks__14__Name - key: name__apigwwm__hc - - name: HealthChecks-UI__HealthChecks__14__Uri - key: internalurls__apigwwm__hc - - name: HealthChecks-UI__HealthChecks__15__Name - key: name__apigwms__hc - - name: HealthChecks-UI__HealthChecks__15__Uri - key: internalurls__apigwms__hc - - name: HealthChecks-UI__HealthChecks__16__Name - key: name__apigwmm__hc - - name: HealthChecks-UI__HealthChecks__16__Uri - key: internalurls__apigwmm__hc + key: internalurls__orderingbackground__hc # values define environment variables with a fixed value (no configmap involved) (name is name of var, and value is its value) values: diff --git a/deploy/k8s/nginx-ingress/cm.yaml b/deploy/k8s/nginx-ingress/cm.yaml deleted file mode 100644 index 7818fd15b..000000000 Binary files a/deploy/k8s/nginx-ingress/cm.yaml and /dev/null differ diff --git a/deploy/k8s/nginx-ingress/local-cm.yaml b/deploy/k8s/nginx-ingress/local-cm.yaml new file mode 100644 index 000000000..02906afc1 --- /dev/null +++ b/deploy/k8s/nginx-ingress/local-cm.yaml @@ -0,0 +1,11 @@ +apiVersion: v1 +kind: ConfigMap +metadata: + labels: + app.kubernetes.io/name: ingress-nginx + app.kubernetes.io/part-of: ingress-nginx + name: nginx-configuration + namespace: ingress-nginx +data: + proxy-buffer-size: "128k" + proxy-buffers: "4 256k" \ No newline at end of file diff --git a/deploy/k8s/nginx-ingress/cloud-generic.yaml b/deploy/k8s/nginx-ingress/local-svc.yaml similarity index 100% rename from deploy/k8s/nginx-ingress/cloud-generic.yaml rename to deploy/k8s/nginx-ingress/local-svc.yaml diff --git a/src/ApiGateways/Envoy/config/mobileshopping/envoy.yaml b/src/ApiGateways/Envoy/config/mobileshopping/envoy.yaml index 373806b06..1ae8c45a1 100644 --- a/src/ApiGateways/Envoy/config/mobileshopping/envoy.yaml +++ b/src/ApiGateways/Envoy/config/mobileshopping/envoy.yaml @@ -42,13 +42,20 @@ static_resources: route: auto_host_rewrite: true prefix_rewrite: "/ordering-api/" - cluster: ordering + cluster: ordering - name: "o-long" match: prefix: "/ordering-api/" route: auto_host_rewrite: true - cluster: ordering + cluster: ordering + - name: "h-long" + match: + prefix: "/hub/notificationhub" + route: + auto_host_rewrite: true + cluster: signalr-hub + timeout: 300s - name: "b-short" match: prefix: "/b/" @@ -61,7 +68,7 @@ static_resources: prefix: "/basket-api/" route: auto_host_rewrite: true - cluster: basket + cluster: basket - name: "agg" match: prefix: "/" @@ -70,25 +77,25 @@ static_resources: prefix_rewrite: "/" cluster: shoppingagg http_filters: - - name: envoy.router + - name: envoy.router access_log: - name: envoy.file_access_log filter: - not_health_check_filter: {} + not_health_check_filter: {} config: json_format: time: "%START_TIME%" protocol: "%PROTOCOL%" duration: "%DURATION%" - request_method: "%REQ(:METHOD)%" - request_host: "%REQ(HOST)%" - path: "%REQ(X-ENVOY-ORIGINAL-PATH?:PATH)%" + request_method: "%REQ(:METHOD)%" + request_host: "%REQ(HOST)%" + path: "%REQ(X-ENVOY-ORIGINAL-PATH?:PATH)%" response_flags: "%RESPONSE_FLAGS%" route_name: "%ROUTE_NAME%" upstream_host: "%UPSTREAM_HOST%" upstream_cluster: "%UPSTREAM_CLUSTER%" - upstream_local_address: "%UPSTREAM_LOCAL_ADDRESS%" - path: "/tmp/access.log" + upstream_local_address: "%UPSTREAM_LOCAL_ADDRESS%" + path: "/tmp/access.log" clusters: - name: shoppingagg connect_timeout: 0.25s @@ -113,7 +120,7 @@ static_resources: hosts: - socket_address: address: basket-api - port_value: 80 + port_value: 80 - name: ordering connect_timeout: 0.25s type: strict_dns @@ -121,4 +128,12 @@ static_resources: hosts: - socket_address: address: ordering-api - port_value: 80 \ No newline at end of file + port_value: 80 + - name: signalr-hub + connect_timeout: 0.25s + type: strict_dns + lb_policy: round_robin + hosts: + - socket_address: + address: ordering-signalrhub + port_value: 80 diff --git a/src/ApiGateways/Envoy/config/webshopping/envoy.yaml b/src/ApiGateways/Envoy/config/webshopping/envoy.yaml index 1491f37af..1ae8c45a1 100644 --- a/src/ApiGateways/Envoy/config/webshopping/envoy.yaml +++ b/src/ApiGateways/Envoy/config/webshopping/envoy.yaml @@ -42,13 +42,20 @@ static_resources: route: auto_host_rewrite: true prefix_rewrite: "/ordering-api/" - cluster: ordering + cluster: ordering - name: "o-long" match: prefix: "/ordering-api/" route: auto_host_rewrite: true - cluster: ordering + cluster: ordering + - name: "h-long" + match: + prefix: "/hub/notificationhub" + route: + auto_host_rewrite: true + cluster: signalr-hub + timeout: 300s - name: "b-short" match: prefix: "/b/" @@ -61,7 +68,7 @@ static_resources: prefix: "/basket-api/" route: auto_host_rewrite: true - cluster: basket + cluster: basket - name: "agg" match: prefix: "/" @@ -70,7 +77,7 @@ static_resources: prefix_rewrite: "/" cluster: shoppingagg http_filters: - - name: envoy.router + - name: envoy.router access_log: - name: envoy.file_access_log filter: @@ -80,15 +87,15 @@ static_resources: time: "%START_TIME%" protocol: "%PROTOCOL%" duration: "%DURATION%" - request_method: "%REQ(:METHOD)%" - request_host: "%REQ(HOST)%" - path: "%REQ(X-ENVOY-ORIGINAL-PATH?:PATH)%" + request_method: "%REQ(:METHOD)%" + request_host: "%REQ(HOST)%" + path: "%REQ(X-ENVOY-ORIGINAL-PATH?:PATH)%" response_flags: "%RESPONSE_FLAGS%" route_name: "%ROUTE_NAME%" upstream_host: "%UPSTREAM_HOST%" upstream_cluster: "%UPSTREAM_CLUSTER%" upstream_local_address: "%UPSTREAM_LOCAL_ADDRESS%" - path: "/tmp/access.log" + path: "/tmp/access.log" clusters: - name: shoppingagg connect_timeout: 0.25s @@ -113,7 +120,7 @@ static_resources: hosts: - socket_address: address: basket-api - port_value: 80 + port_value: 80 - name: ordering connect_timeout: 0.25s type: strict_dns @@ -121,4 +128,12 @@ static_resources: hosts: - socket_address: address: ordering-api - port_value: 80 \ No newline at end of file + port_value: 80 + - name: signalr-hub + connect_timeout: 0.25s + type: strict_dns + lb_policy: round_robin + hosts: + - socket_address: + address: ordering-signalrhub + port_value: 80 diff --git a/src/Services/Identity/Identity.API/Views/Shared/_Layout.cshtml b/src/Services/Identity/Identity.API/Views/Shared/_Layout.cshtml index 4727229c7..1d57c688e 100644 --- a/src/Services/Identity/Identity.API/Views/Shared/_Layout.cshtml +++ b/src/Services/Identity/Identity.API/Views/Shared/_Layout.cshtml @@ -3,6 +3,7 @@
+