From 65c9817295f7597fdc890758a36fc5db9f11ba68 Mon Sep 17 00:00:00 2001 From: stefanprodan Date: Fri, 26 Jul 2019 13:51:15 +0300 Subject: [PATCH 01/12] Remove test artifacts --- artifacts/cluster/releases/test/backend.yaml | 6 +- artifacts/cluster/releases/test/frontend.yaml | 6 +- .../cluster/releases/test/loadtester.yaml | 6 +- artifacts/configs/canary.yaml | 59 ------------ artifacts/configs/configs.yaml | 16 ---- artifacts/configs/deployment.yaml | 89 ------------------- artifacts/configs/hpa.yaml | 19 ---- artifacts/configs/secrets.yaml | 16 ---- artifacts/routing/destination-rule.yaml | 45 ---------- artifacts/routing/match.yaml | 43 --------- artifacts/routing/mirror.yaml | 25 ------ artifacts/routing/weight.yaml | 26 ------ artifacts/workloads/canary-deployment.yaml | 69 -------------- artifacts/workloads/canary-destination.yaml | 13 --- artifacts/workloads/canary-hpa.yaml | 23 ----- artifacts/workloads/canary-service.yaml | 14 --- artifacts/workloads/primary-deployment.yaml | 71 --------------- artifacts/workloads/primary-destination.yaml | 13 --- artifacts/workloads/primary-hpa.yaml | 19 ---- artifacts/workloads/primary-service.yaml | 16 ---- artifacts/workloads/service.yaml | 14 --- artifacts/workloads/virtual-service.yaml | 23 ----- 22 files changed, 9 insertions(+), 622 deletions(-) delete mode 100644 artifacts/configs/canary.yaml delete mode 100644 artifacts/configs/configs.yaml delete mode 100644 artifacts/configs/deployment.yaml delete mode 100644 artifacts/configs/hpa.yaml delete mode 100644 artifacts/configs/secrets.yaml delete mode 100644 artifacts/routing/destination-rule.yaml delete mode 100644 artifacts/routing/match.yaml delete mode 100644 artifacts/routing/mirror.yaml delete mode 100644 artifacts/routing/weight.yaml delete mode 100644 artifacts/workloads/canary-deployment.yaml delete mode 100644 artifacts/workloads/canary-destination.yaml delete mode 100644 artifacts/workloads/canary-hpa.yaml delete mode 100644 artifacts/workloads/canary-service.yaml delete mode 100644 artifacts/workloads/primary-deployment.yaml delete mode 100644 artifacts/workloads/primary-destination.yaml delete mode 100644 artifacts/workloads/primary-hpa.yaml delete mode 100644 artifacts/workloads/primary-service.yaml delete mode 100644 artifacts/workloads/service.yaml delete mode 100644 artifacts/workloads/virtual-service.yaml diff --git a/artifacts/cluster/releases/test/backend.yaml b/artifacts/cluster/releases/test/backend.yaml index d29e4903..79ac9bbb 100644 --- a/artifacts/cluster/releases/test/backend.yaml +++ b/artifacts/cluster/releases/test/backend.yaml @@ -5,17 +5,17 @@ metadata: namespace: test annotations: flux.weave.works/automated: "true" - flux.weave.works/tag.chart-image: regexp:^1.4.* + flux.weave.works/tag.chart-image: regexp:^1.7.* spec: releaseName: backend chart: repository: https://flagger.app/ name: podinfo - version: 2.0.0 + version: 2.2.0 values: image: repository: quay.io/stefanprodan/podinfo - tag: 1.4.0 + tag: 1.7.0 httpServer: timeout: 30s canary: diff --git a/artifacts/cluster/releases/test/frontend.yaml b/artifacts/cluster/releases/test/frontend.yaml index f2fa539c..0a62c895 100644 --- a/artifacts/cluster/releases/test/frontend.yaml +++ b/artifacts/cluster/releases/test/frontend.yaml @@ -5,17 +5,17 @@ metadata: namespace: test annotations: flux.weave.works/automated: "true" - flux.weave.works/tag.chart-image: semver:~1.4 + flux.weave.works/tag.chart-image: semver:~1.7 spec: releaseName: frontend chart: repository: https://flagger.app/ name: podinfo - version: 2.0.0 + version: 2.2.0 values: image: repository: quay.io/stefanprodan/podinfo - tag: 1.4.0 + tag: 1.7.0 backend: http://backend-podinfo:9898/echo canary: enabled: true diff --git a/artifacts/cluster/releases/test/loadtester.yaml b/artifacts/cluster/releases/test/loadtester.yaml index d098b9f2..bd742d60 100644 --- a/artifacts/cluster/releases/test/loadtester.yaml +++ b/artifacts/cluster/releases/test/loadtester.yaml @@ -11,8 +11,8 @@ spec: chart: repository: https://flagger.app/ name: loadtester - version: 0.1.0 + version: 0.6.0 values: image: - repository: quay.io/stefanprodan/flagger-loadtester - tag: 0.1.0 + repository: weaveworks/flagger-loadtester + tag: 0.6.1 diff --git a/artifacts/configs/canary.yaml b/artifacts/configs/canary.yaml deleted file mode 100644 index 9e666222..00000000 --- a/artifacts/configs/canary.yaml +++ /dev/null @@ -1,59 +0,0 @@ -apiVersion: flagger.app/v1alpha3 -kind: Canary -metadata: - name: podinfo - namespace: test -spec: - # deployment reference - targetRef: - apiVersion: apps/v1 - kind: Deployment - name: podinfo - # the maximum time in seconds for the canary deployment - # to make progress before it is rollback (default 600s) - progressDeadlineSeconds: 60 - # HPA reference (optional) - autoscalerRef: - apiVersion: autoscaling/v2beta1 - kind: HorizontalPodAutoscaler - name: podinfo - service: - # container port - port: 9898 - # Istio gateways (optional) - gateways: - - public-gateway.istio-system.svc.cluster.local - - mesh - # Istio virtual service host names (optional) - hosts: - - app.iowa.weavedx.com - canaryAnalysis: - # schedule interval (default 60s) - interval: 10s - # max number of failed metric checks before rollback - threshold: 10 - # max traffic percentage routed to canary - # percentage (0-100) - maxWeight: 50 - # canary increment step - # percentage (0-100) - stepWeight: 5 - # Istio Prometheus checks - metrics: - - name: request-success-rate - # minimum req success rate (non 5xx responses) - # percentage (0-100) - threshold: 99 - interval: 1m - - name: request-duration - # maximum req duration P99 - # milliseconds - threshold: 500 - interval: 30s - # external checks (optional) - webhooks: - - name: load-test - url: http://flagger-loadtester.test/ - timeout: 5s - metadata: - cmd: "hey -z 1m -q 10 -c 2 http://podinfo.test:9898/" diff --git a/artifacts/configs/configs.yaml b/artifacts/configs/configs.yaml deleted file mode 100644 index 8e3cfe50..00000000 --- a/artifacts/configs/configs.yaml +++ /dev/null @@ -1,16 +0,0 @@ -apiVersion: v1 -kind: ConfigMap -metadata: - name: podinfo-config-env - namespace: test -data: - color: blue ---- -apiVersion: v1 -kind: ConfigMap -metadata: - name: podinfo-config-vol - namespace: test -data: - output: console - textmode: "true" diff --git a/artifacts/configs/deployment.yaml b/artifacts/configs/deployment.yaml deleted file mode 100644 index 1d2fbe45..00000000 --- a/artifacts/configs/deployment.yaml +++ /dev/null @@ -1,89 +0,0 @@ -apiVersion: apps/v1 -kind: Deployment -metadata: - name: podinfo - namespace: test - labels: - app: podinfo -spec: - minReadySeconds: 5 - revisionHistoryLimit: 5 - progressDeadlineSeconds: 60 - strategy: - rollingUpdate: - maxUnavailable: 0 - type: RollingUpdate - selector: - matchLabels: - app: podinfo - template: - metadata: - annotations: - prometheus.io/scrape: "true" - labels: - app: podinfo - spec: - containers: - - name: podinfod - image: quay.io/stefanprodan/podinfo:1.3.0 - imagePullPolicy: IfNotPresent - ports: - - containerPort: 9898 - name: http - protocol: TCP - command: - - ./podinfo - - --port=9898 - - --level=info - - --random-delay=false - - --random-error=false - env: - - name: PODINFO_UI_COLOR - valueFrom: - configMapKeyRef: - name: podinfo-config-env - key: color - - name: SECRET_USER - valueFrom: - secretKeyRef: - name: podinfo-secret-env - key: user - livenessProbe: - exec: - command: - - podcli - - check - - http - - localhost:9898/healthz - initialDelaySeconds: 5 - timeoutSeconds: 5 - readinessProbe: - exec: - command: - - podcli - - check - - http - - localhost:9898/readyz - initialDelaySeconds: 5 - timeoutSeconds: 5 - resources: - limits: - cpu: 2000m - memory: 512Mi - requests: - cpu: 100m - memory: 64Mi - volumeMounts: - - name: configs - mountPath: /etc/podinfo/configs - readOnly: true - - name: secrets - mountPath: /etc/podinfo/secrets - readOnly: true - volumes: - - name: configs - configMap: - name: podinfo-config-vol - - name: secrets - secret: - secretName: podinfo-secret-vol diff --git a/artifacts/configs/hpa.yaml b/artifacts/configs/hpa.yaml deleted file mode 100644 index 48ec76e8..00000000 --- a/artifacts/configs/hpa.yaml +++ /dev/null @@ -1,19 +0,0 @@ -apiVersion: autoscaling/v2beta1 -kind: HorizontalPodAutoscaler -metadata: - name: podinfo - namespace: test -spec: - scaleTargetRef: - apiVersion: apps/v1 - kind: Deployment - name: podinfo - minReplicas: 1 - maxReplicas: 4 - metrics: - - type: Resource - resource: - name: cpu - # scale up if usage is above - # 99% of the requested CPU (100m) - targetAverageUtilization: 99 diff --git a/artifacts/configs/secrets.yaml b/artifacts/configs/secrets.yaml deleted file mode 100644 index 73485871..00000000 --- a/artifacts/configs/secrets.yaml +++ /dev/null @@ -1,16 +0,0 @@ -apiVersion: v1 -kind: Secret -metadata: - name: podinfo-secret-env - namespace: test -data: - password: cGFzc3dvcmQ= - user: YWRtaW4= ---- -apiVersion: v1 -kind: Secret -metadata: - name: podinfo-secret-vol - namespace: test -data: - key: cGFzc3dvcmQ= diff --git a/artifacts/routing/destination-rule.yaml b/artifacts/routing/destination-rule.yaml deleted file mode 100644 index 2bdea8f2..00000000 --- a/artifacts/routing/destination-rule.yaml +++ /dev/null @@ -1,45 +0,0 @@ -apiVersion: networking.istio.io/v1alpha3 -kind: VirtualService -metadata: - name: podinfo - namespace: test -spec: - gateways: - - public-gateway.istio-system.svc.cluster.local - - mesh - hosts: - - podinfo.istio.weavedx.com - - podinfo - http: - - route: - - destination: - host: podinfo - subset: primary - weight: 50 - - destination: - host: podinfo - subset: canary - weight: 50 ---- -apiVersion: networking.istio.io/v1alpha3 -kind: DestinationRule -metadata: - name: podinfo-destination - namespace: test -spec: - host: podinfo - trafficPolicy: - loadBalancer: - consistentHash: - httpCookie: - name: istiouser - ttl: 30s - subsets: - - name: primary - labels: - app: podinfo - role: primary - - name: canary - labels: - app: podinfo - role: canary diff --git a/artifacts/routing/match.yaml b/artifacts/routing/match.yaml deleted file mode 100644 index edf76586..00000000 --- a/artifacts/routing/match.yaml +++ /dev/null @@ -1,43 +0,0 @@ -apiVersion: networking.istio.io/v1alpha3 -kind: VirtualService -metadata: - name: podinfo - namespace: test -spec: - gateways: - - public-gateway.istio-system.svc.cluster.local - - mesh - hosts: - - app.istio.weavedx.com - - podinfo - http: - - match: - - headers: - user-agent: - regex: ^(?!.*Chrome)(?=.*\bSafari\b).*$ - uri: - prefix: "/version/" - rewrite: - uri: /api/info - route: - - destination: - host: podinfo-primary - port: - number: 9898 - weight: 0 - - destination: - host: podinfo - port: - number: 9898 - weight: 100 - - match: - - uri: - prefix: "/version/" - rewrite: - uri: /api/info - route: - - destination: - host: podinfo-primary - port: - number: 9898 - weight: 100 diff --git a/artifacts/routing/mirror.yaml b/artifacts/routing/mirror.yaml deleted file mode 100644 index 274c0947..00000000 --- a/artifacts/routing/mirror.yaml +++ /dev/null @@ -1,25 +0,0 @@ -apiVersion: networking.istio.io/v1alpha3 -kind: VirtualService -metadata: - name: podinfo - namespace: test - labels: - app: podinfo -spec: - gateways: - - public-gateway.istio-system.svc.cluster.local - - mesh - hosts: - - podinfo.iowa.weavedx.com - - podinfo - http: - - route: - - destination: - host: podinfo-primary - port: - number: 9898 - weight: 100 - mirror: - host: podinfo - port: - number: 9898 diff --git a/artifacts/routing/weight.yaml b/artifacts/routing/weight.yaml deleted file mode 100644 index 5a16f5c3..00000000 --- a/artifacts/routing/weight.yaml +++ /dev/null @@ -1,26 +0,0 @@ -apiVersion: networking.istio.io/v1alpha3 -kind: VirtualService -metadata: - name: podinfo - namespace: test - labels: - app: podinfo -spec: - gateways: - - public-gateway.istio-system.svc.cluster.local - - mesh - hosts: - - podinfo.iowa.weavedx.com - - podinfo - http: - - route: - - destination: - host: podinfo-primary - port: - number: 9898 - weight: 100 - - destination: - host: podinfo - port: - number: 9898 - weight: 0 diff --git a/artifacts/workloads/canary-deployment.yaml b/artifacts/workloads/canary-deployment.yaml deleted file mode 100644 index 4baf9424..00000000 --- a/artifacts/workloads/canary-deployment.yaml +++ /dev/null @@ -1,69 +0,0 @@ -apiVersion: apps/v1 -kind: Deployment -metadata: - name: podinfo - namespace: test - labels: - app: podinfo -spec: - replicas: 1 - strategy: - rollingUpdate: - maxUnavailable: 0 - type: RollingUpdate - selector: - matchLabels: - app: podinfo - template: - metadata: - annotations: - prometheus.io/scrape: "true" - labels: - app: podinfo - spec: - containers: - - name: podinfod - image: quay.io/stefanprodan/podinfo:1.7.0 - imagePullPolicy: IfNotPresent - ports: - - containerPort: 9898 - name: http - protocol: TCP - command: - - ./podinfo - - --port=9898 - - --level=info - - --random-delay=false - - --random-error=false - env: - - name: PODINFO_UI_COLOR - value: green - livenessProbe: - exec: - command: - - podcli - - check - - http - - localhost:9898/healthz - failureThreshold: 3 - periodSeconds: 10 - successThreshold: 1 - timeoutSeconds: 2 - readinessProbe: - exec: - command: - - podcli - - check - - http - - localhost:9898/readyz - failureThreshold: 3 - periodSeconds: 3 - successThreshold: 1 - timeoutSeconds: 2 - resources: - limits: - cpu: 1000m - memory: 256Mi - requests: - cpu: 100m - memory: 16Mi diff --git a/artifacts/workloads/canary-destination.yaml b/artifacts/workloads/canary-destination.yaml deleted file mode 100644 index 761a21a7..00000000 --- a/artifacts/workloads/canary-destination.yaml +++ /dev/null @@ -1,13 +0,0 @@ -apiVersion: networking.istio.io/v1alpha3 -kind: DestinationRule -metadata: - name: podinfo-canary - namespace: test -spec: - host: podinfo-canary - trafficPolicy: - loadBalancer: - consistentHash: - httpCookie: - name: user - ttl: 0s \ No newline at end of file diff --git a/artifacts/workloads/canary-hpa.yaml b/artifacts/workloads/canary-hpa.yaml deleted file mode 100644 index 9ffce478..00000000 --- a/artifacts/workloads/canary-hpa.yaml +++ /dev/null @@ -1,23 +0,0 @@ -apiVersion: autoscaling/v2beta1 -kind: HorizontalPodAutoscaler -metadata: - name: podinfo - namespace: test -spec: - scaleTargetRef: - apiVersion: apps/v1 - kind: Deployment - name: podinfo - minReplicas: 2 - maxReplicas: 2 - metrics: - - type: Resource - resource: - name: cpu - # scale up if usage is above - # 99% of the requested CPU (100m) - targetAverageUtilization: 99 - - type: Resource - resource: - name: memory - targetAverageValue: 200Mi diff --git a/artifacts/workloads/canary-service.yaml b/artifacts/workloads/canary-service.yaml deleted file mode 100644 index 7a09e206..00000000 --- a/artifacts/workloads/canary-service.yaml +++ /dev/null @@ -1,14 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: podinfo-canary - namespace: test -spec: - type: ClusterIP - selector: - app: podinfo - ports: - - name: http - port: 9898 - protocol: TCP - targetPort: http diff --git a/artifacts/workloads/primary-deployment.yaml b/artifacts/workloads/primary-deployment.yaml deleted file mode 100644 index 6bc393a7..00000000 --- a/artifacts/workloads/primary-deployment.yaml +++ /dev/null @@ -1,71 +0,0 @@ -apiVersion: apps/v1 -kind: Deployment -metadata: - name: podinfo-primary - namespace: test - labels: - app: podinfo-primary -spec: - replicas: 1 - strategy: - rollingUpdate: - maxUnavailable: 0 - type: RollingUpdate - selector: - matchLabels: - app: podinfo-primary - template: - metadata: - annotations: - prometheus.io/scrape: "true" - labels: - app: podinfo-primary - spec: - containers: - - name: podinfod - image: quay.io/stefanprodan/podinfo:1.7.1 - imagePullPolicy: IfNotPresent - ports: - - containerPort: 9898 - name: http - protocol: TCP - command: - - ./podinfo - - --port=9898 - - --level=info - - --random-delay=false - - --random-error=false - env: - - name: PODINFO_UI_COLOR - value: blue - livenessProbe: - exec: - command: - - podcli - - check - - http - - localhost:9898/healthz - initialDelaySeconds: 5 - failureThreshold: 3 - periodSeconds: 10 - successThreshold: 1 - timeoutSeconds: 1 - readinessProbe: - exec: - command: - - podcli - - check - - http - - localhost:9898/readyz - initialDelaySeconds: 5 - failureThreshold: 3 - periodSeconds: 3 - successThreshold: 1 - timeoutSeconds: 1 - resources: - limits: - cpu: 2000m - memory: 512Mi - requests: - cpu: 10m - memory: 64Mi diff --git a/artifacts/workloads/primary-destination.yaml b/artifacts/workloads/primary-destination.yaml deleted file mode 100644 index d84b1962..00000000 --- a/artifacts/workloads/primary-destination.yaml +++ /dev/null @@ -1,13 +0,0 @@ -apiVersion: networking.istio.io/v1alpha3 -kind: DestinationRule -metadata: - name: podinfo-primary - namespace: test -spec: - host: podinfo-primary - trafficPolicy: - loadBalancer: - consistentHash: - httpCookie: - name: user - ttl: 0s diff --git a/artifacts/workloads/primary-hpa.yaml b/artifacts/workloads/primary-hpa.yaml deleted file mode 100644 index 0b762122..00000000 --- a/artifacts/workloads/primary-hpa.yaml +++ /dev/null @@ -1,19 +0,0 @@ -apiVersion: autoscaling/v2beta1 -kind: HorizontalPodAutoscaler -metadata: - name: podinfo-primary - namespace: test -spec: - scaleTargetRef: - apiVersion: apps/v1 - kind: Deployment - name: podinfo-primary - minReplicas: 2 - maxReplicas: 2 - metrics: - - type: Resource - resource: - name: cpu - # scale up if usage is above - # 99% of the requested CPU (100m) - targetAverageUtilization: 99 diff --git a/artifacts/workloads/primary-service.yaml b/artifacts/workloads/primary-service.yaml deleted file mode 100644 index b5290e28..00000000 --- a/artifacts/workloads/primary-service.yaml +++ /dev/null @@ -1,16 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: podinfo-primary - namespace: test - labels: - app: podinfo-primary -spec: - type: ClusterIP - selector: - app: podinfo-primary - ports: - - name: http - port: 9898 - protocol: TCP - targetPort: http diff --git a/artifacts/workloads/service.yaml b/artifacts/workloads/service.yaml deleted file mode 100644 index 3e98f1e0..00000000 --- a/artifacts/workloads/service.yaml +++ /dev/null @@ -1,14 +0,0 @@ -apiVersion: v1 -kind: Service -metadata: - name: podinfo - namespace: test -spec: - type: ClusterIP - selector: - app: podinfo-primary - ports: - - name: http - port: 9898 - protocol: TCP - targetPort: http diff --git a/artifacts/workloads/virtual-service.yaml b/artifacts/workloads/virtual-service.yaml deleted file mode 100644 index b2c59e45..00000000 --- a/artifacts/workloads/virtual-service.yaml +++ /dev/null @@ -1,23 +0,0 @@ -apiVersion: networking.istio.io/v1alpha3 -kind: VirtualService -metadata: - name: podinfo - namespace: test - labels: - app: podinfo -spec: - gateways: - - mesh - - public-gateway.istio-system.svc.cluster.local - hosts: - - podinfo - - app.istio.weavedx.com - http: - - route: - - destination: - host: podinfo-primary - weight: 50 - - destination: - host: podinfo-canary - weight: 50 - timeout: 5s From 83046282c35077dac8fd6eb7b50ea26076cec0f5 Mon Sep 17 00:00:00 2001 From: stefanprodan Date: Fri, 26 Jul 2019 13:53:40 +0300 Subject: [PATCH 02/12] Release v0.18.0 --- artifacts/flagger/deployment.yaml | 2 +- charts/flagger/Chart.yaml | 4 ++-- charts/flagger/values.yaml | 2 +- kustomize/base/flagger/kustomization.yaml | 2 +- pkg/version/version.go | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/artifacts/flagger/deployment.yaml b/artifacts/flagger/deployment.yaml index e387b095..23fa4698 100644 --- a/artifacts/flagger/deployment.yaml +++ b/artifacts/flagger/deployment.yaml @@ -22,7 +22,7 @@ spec: serviceAccountName: flagger containers: - name: flagger - image: weaveworks/flagger:0.17.0 + image: weaveworks/flagger:0.18.0 imagePullPolicy: IfNotPresent ports: - name: http diff --git a/charts/flagger/Chart.yaml b/charts/flagger/Chart.yaml index 959f0b00..ce24890d 100644 --- a/charts/flagger/Chart.yaml +++ b/charts/flagger/Chart.yaml @@ -1,7 +1,7 @@ apiVersion: v1 name: flagger -version: 0.17.0 -appVersion: 0.17.0 +version: 0.18.0 +appVersion: 0.18.0 kubeVersion: ">=1.11.0-0" engine: gotpl description: Flagger is a Kubernetes operator that automates the promotion of canary deployments using Istio, App Mesh or NGINX routing for traffic shifting and Prometheus metrics for canary analysis. diff --git a/charts/flagger/values.yaml b/charts/flagger/values.yaml index 7adea618..88523651 100644 --- a/charts/flagger/values.yaml +++ b/charts/flagger/values.yaml @@ -2,7 +2,7 @@ image: repository: weaveworks/flagger - tag: 0.17.0 + tag: 0.18.0 pullPolicy: IfNotPresent metricsServer: "http://prometheus:9090" diff --git a/kustomize/base/flagger/kustomization.yaml b/kustomize/base/flagger/kustomization.yaml index 1eb01eac..acfff82d 100644 --- a/kustomize/base/flagger/kustomization.yaml +++ b/kustomize/base/flagger/kustomization.yaml @@ -8,4 +8,4 @@ resources: - deployment.yaml images: - name: weaveworks/flagger - newTag: 0.17.0 + newTag: 0.18.0 diff --git a/pkg/version/version.go b/pkg/version/version.go index 7ee4a5f4..5f5b313e 100644 --- a/pkg/version/version.go +++ b/pkg/version/version.go @@ -1,4 +1,4 @@ package version -var VERSION = "0.17.0" +var VERSION = "0.18.0" var REVISION = "unknown" From 0c6a7355e7826763e3083c1457018acc4e4294fe Mon Sep 17 00:00:00 2001 From: stefanprodan Date: Fri, 26 Jul 2019 14:05:19 +0300 Subject: [PATCH 03/12] Add v0.18.0 to changelog --- CHANGELOG.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index c09358e8..ad8520af 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,24 @@ All notable changes to this project are documented in this file. +## 0.18.0 (2019-07-26) + +Adds support for [manual gating](https://docs.flagger.app/how-it-works#manual-gating) + +#### Features + +- Implement confirm rollout gate, hook and API [#251](https://github.com/weaveworks/flagger/pull/251) + +#### Improvements + +- Refactor canary change detection and status [#240](https://github.com/weaveworks/flagger/pull/240) +- Add gRPC load testing tool [#248](https://github.com/weaveworks/flagger/pull/248) + +#### Breaking changes + +- due to the status sub-resource changes in [#240](https://github.com/weaveworks/flagger/pull/240), when upgrading Flagger the canaries status phase will be reset to `Initialized` +- upgrading Flagger with Helm will fail due to Helm poor support of CRDs, see [workaround](https://github.com/weaveworks/flagger/issues/223) + ## 0.17.0 (2019-07-08) Adds support for Linkerd (SMI Traffic Split API), MS Teams notifications and HA mode with leader election From e1dacc39831c872ed7e236e14f5f2f454fbfba80 Mon Sep 17 00:00:00 2001 From: stefanprodan Date: Fri, 26 Jul 2019 15:45:20 +0300 Subject: [PATCH 04/12] Use kubectl for CRD install --- docs/gitbook/install/flagger-install-on-kubernetes.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/docs/gitbook/install/flagger-install-on-kubernetes.md b/docs/gitbook/install/flagger-install-on-kubernetes.md index 2a827bfd..6bc08df6 100644 --- a/docs/gitbook/install/flagger-install-on-kubernetes.md +++ b/docs/gitbook/install/flagger-install-on-kubernetes.md @@ -11,6 +11,12 @@ Flagger requires a Kubernetes cluster **v1.11** or newer with the following admi ### Install Flagger with Helm +Install Flagger's Canary CRD: + +```yaml +kubectl apply -f https://raw.githubusercontent.com/weaveworks/flagger/master/artifacts/flagger/crd.yaml +``` + Add Flagger Helm repository: ```bash @@ -22,6 +28,7 @@ Deploy Flagger for Istio: ```bash helm upgrade -i flagger flagger/flagger \ --namespace=istio-system \ +--set crd.create=false \ --set meshProvider=istio \ --set metricsServer=http://prometheus:9090 ``` @@ -31,6 +38,7 @@ Deploy Flagger for Linkerd: ```bash helm upgrade -i flagger flagger/flagger \ --namespace=linkerd \ +--set crd.create=false \ --set meshProvider=linkerd \ --set metricsServer=http://linkerd-prometheus:9090 ``` @@ -42,6 +50,7 @@ Enable **Slack** notifications: ```bash helm upgrade -i flagger flagger/flagger \ --namespace=istio-system \ +--set crd.create=false \ --set slack.url=https://hooks.slack.com/services/YOUR/SLACK/WEBHOOK \ --set slack.channel=general \ --set slack.user=flagger @@ -52,6 +61,7 @@ Enable **Microsoft Teams** notifications: ```bash helm upgrade -i flagger flagger/flagger \ --namespace=istio-system \ +--set crd.create=false \ --set msteams.url=https://outlook.office.com/webhook/YOUR/TEAMS/WEBHOOK ``` From 8bea9253c3db1825567be4b5bb34d42bc93e938e Mon Sep 17 00:00:00 2001 From: stefanprodan Date: Sat, 27 Jul 2019 13:06:27 +0300 Subject: [PATCH 05/12] Add CRD install step to chart --- charts/flagger/Chart.yaml | 3 ++- charts/flagger/README.md | 12 +++++++++--- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/charts/flagger/Chart.yaml b/charts/flagger/Chart.yaml index ce24890d..6b2d7287 100644 --- a/charts/flagger/Chart.yaml +++ b/charts/flagger/Chart.yaml @@ -4,7 +4,7 @@ version: 0.18.0 appVersion: 0.18.0 kubeVersion: ">=1.11.0-0" engine: gotpl -description: Flagger is a Kubernetes operator that automates the promotion of canary deployments using Istio, App Mesh or NGINX routing for traffic shifting and Prometheus metrics for canary analysis. +description: Flagger is a Kubernetes operator that automates the promotion of canary deployments using Istio, Linkerd, App Mesh, Gloo or NGINX routing for traffic shifting and Prometheus metrics for canary analysis. home: https://docs.flagger.app icon: https://raw.githubusercontent.com/weaveworks/flagger/master/docs/logo/flagger-icon.png sources: @@ -17,4 +17,5 @@ keywords: - canary - istio - appmesh +- linkerd - gitops diff --git a/charts/flagger/README.md b/charts/flagger/README.md index 12e91463..657cca17 100644 --- a/charts/flagger/README.md +++ b/charts/flagger/README.md @@ -1,10 +1,10 @@ # Flagger [Flagger](https://github.com/weaveworks/flagger) is a Kubernetes operator that automates the promotion of -canary deployments using Istio, App Mesh, NGINX or Gloo routing for traffic shifting and Prometheus metrics for canary analysis. +canary deployments using Istio, Linkerd, App Mesh, NGINX or Gloo routing for traffic shifting and Prometheus metrics for canary analysis. Flagger implements a control loop that gradually shifts traffic to the canary while measuring key performance indicators like HTTP requests success rate, requests average duration and pods health. -Based on the KPIs analysis a canary is promoted or aborted and the analysis result is published to Slack. +Based on the KPIs analysis a canary is promoted or aborted and the analysis result is published to Slack or MS Teams. ## Prerequisites @@ -16,7 +16,13 @@ Based on the KPIs analysis a canary is promoted or aborted and the analysis resu Add Flagger Helm repository: ```console -helm repo add flagger https://flagger.app +$ helm repo add flagger https://flagger.app +``` + +Install Flagger's custom resource definitions: + +```console +$ kubectl apply -f https://raw.githubusercontent.com/weaveworks/flagger/master/artifacts/flagger/crd.yaml ``` To install the chart with the release name `flagger` for Istio: From 0a2c134ece8c05c0886b68abb78a9ee3d63fe8db Mon Sep 17 00:00:00 2001 From: stefanprodan Date: Sat, 27 Jul 2019 13:07:47 +0300 Subject: [PATCH 06/12] Add kubectl min version to Kustomize docs --- .../install/flagger-install-on-kubernetes.md | 9 ++- kustomize/README.md | 59 ++++++++++++++++--- 2 files changed, 57 insertions(+), 11 deletions(-) diff --git a/docs/gitbook/install/flagger-install-on-kubernetes.md b/docs/gitbook/install/flagger-install-on-kubernetes.md index 6bc08df6..e03f48a4 100644 --- a/docs/gitbook/install/flagger-install-on-kubernetes.md +++ b/docs/gitbook/install/flagger-install-on-kubernetes.md @@ -135,6 +135,7 @@ kubectl -n istio-system port-forward svc/flagger-grafana 3000:80 ### Install Flagger with Kustomize As an alternative to Helm, Flagger can be installed with Kustomize. +Note that you'll need kubectl 1.14 or newer that comes with the Kustomize commands. **Service mesh specific installers** @@ -144,7 +145,7 @@ Install Flagger for Istio: kubectl apply -k github.com/weaveworks/flagger/kustomize/istio ``` -This deploys Flagger in the `istio-system` namespace and sets the metrics server URL to `http://prometheus.istio-system:9090`. +This deploys Flagger in the `istio-system` namespace and sets the metrics server URL to Istio's Prometheus instance. Install Flagger for Linkerd: @@ -152,7 +153,7 @@ Install Flagger for Linkerd: kubectl apply -k github.com/weaveworks/flagger/kustomize/linkerd ``` -This deploys Flagger in the `linkerd` namespace and sets the metrics server URL to `http://linkerd-prometheus.linkerd:9090`. +This deploys Flagger in the `linkerd` namespace and sets the metrics server URL to Linkerd's Prometheus instance. **Generic installer** @@ -168,7 +169,7 @@ sets the metrics server URL to `http://flagger-prometheus.flagger-system:9090` a The Prometheus instance has a two hours data retention and is configured to scrape all pods in your cluster that have the `prometheus.io/scrape: "true"` annotation. -To target a specific provider you need to specify it in the canary custom resource: +To target a different provider you can specify it in the canary custom resource: ```yaml apiVersion: flagger.app/v1alpha3 @@ -223,3 +224,5 @@ Install Flagger with Slack: ```bash kubectl apply -k . ``` + +If you want to use MS Teams instead of Slack, replace `-slack-url` with `-msteams-url` and set the webhook address to `https://outlook.office.com/webhook/YOUR/TEAMS/WEBHOOK`. diff --git a/kustomize/README.md b/kustomize/README.md index 343725aa..3349364c 100644 --- a/kustomize/README.md +++ b/kustomize/README.md @@ -1,13 +1,14 @@ # Flagger Kustomize installer -As an alternative to Helm, Flagger can be installed with Kustomize. +As an alternative to Helm, Flagger can be installed with [Kustomize](https://kustomize.io/). +Note that you'll need kubectl 1.14 or newer that comes with the Kustomize commands. ## Service mesh specific installers Install Flagger for Istio: ```bash -kubectl apply -k github.com/weaveworks/flagger/kustomize/istio +kubectl apply -k github.com/weaveworks/flagger//kustomize/istio ``` This deploys Flagger in the `istio-system` namespace and sets the metrics server URL to `http://prometheus.istio-system:9090`. @@ -15,7 +16,7 @@ This deploys Flagger in the `istio-system` namespace and sets the metrics server Install Flagger for Linkerd: ```bash -kubectl apply -k github.com/weaveworks/flagger/kustomize/linkerd +kubectl apply -k github.com/weaveworks/flagger//kustomize/linkerd ``` This deploys Flagger in the `linkerd` namespace and sets the metrics server URL to `http://linkerd-prometheus.linkerd:9090`. @@ -25,13 +26,16 @@ This deploys Flagger in the `linkerd` namespace and sets the metrics server URL Install Flagger and Prometheus: ```bash -kubectl apply -k github.com/weaveworks/flagger/kustomize/kubernetes +kubectl apply -k github.com/weaveworks/flagger//kustomize/kubernetes ``` This deploys Flagger and Prometheus in the `flagger-system` namespace, sets the metrics server URL to `http://flagger-prometheus.flagger-system:9090` and the mesh provider to `kubernetes`. -To target a specific provider you need to specify it in the canary custom resource: +The Prometheus instance has a two hours data retention and is configured to scrape all pods in your cluster that +have the `prometheus.io/scrape: "true"` annotation. + +To target a different provider you can specify it in the canary custom resource: ```yaml apiVersion: flagger.app/v1alpha3 @@ -40,12 +44,12 @@ metadata: name: app namespace: test spec: - # can be: kubernetes, istio, appmesh, linkerd, smi, nginx, gloo, supergloo + # can be: kubernetes, appmesh, nginx, gloo # use the kubernetes provider for Blue/Green style deployments provider: nginx ``` -## Customized installer +## Configure Slack notifications Create a kustomization file using flagger as base: @@ -81,9 +85,48 @@ spec: EOF ``` -Install Flagger with Slack: +Install Flagger for Istio with Slack notifications: ```bash kubectl apply -k . ``` +## Configure MS Teams notifications + +Create a kustomization file using flagger as base: + +```bash +cat > kustomization.yaml < patch.yaml < Date: Sat, 27 Jul 2019 13:17:08 +0300 Subject: [PATCH 07/12] Use crd.create=false in docs --- charts/flagger/README.md | 3 +++ .../install/flagger-install-on-eks-appmesh.md | 8 ++++++++ .../install/flagger-install-on-google-cloud.md | 7 +++++++ .../gitbook/install/flagger-install-on-kubernetes.md | 12 ++++++------ .../install/flagger-install-with-supergloo.md | 7 +++++++ 5 files changed, 31 insertions(+), 6 deletions(-) diff --git a/charts/flagger/README.md b/charts/flagger/README.md index 657cca17..e5e9ba7a 100644 --- a/charts/flagger/README.md +++ b/charts/flagger/README.md @@ -30,6 +30,7 @@ To install the chart with the release name `flagger` for Istio: ```console $ helm upgrade -i flagger flagger/flagger \ --namespace=istio-system \ + --set crd.create=false \ --set meshProvider=istio \ --set metricsServer=http://prometheus:9090 ``` @@ -39,6 +40,7 @@ To install the chart with the release name `flagger` for Linkerd: ```console $ helm upgrade -i flagger flagger/flagger \ --namespace=linkerd \ + --set crd.create=false \ --set meshProvider=linkerd \ --set metricsServer=http://linkerd-prometheus:9090 ``` @@ -88,6 +90,7 @@ Specify each parameter using the `--set key=value[,key=value]` argument to `helm ```console $ helm upgrade -i flagger flagger/flagger \ --namespace istio-system \ + --set crd.create=false \ --set slack.url=https://hooks.slack.com/services/YOUR/SLACK/WEBHOOK \ --set slack.channel=general ``` diff --git a/docs/gitbook/install/flagger-install-on-eks-appmesh.md b/docs/gitbook/install/flagger-install-on-eks-appmesh.md index 7e4edde1..b8bf41af 100644 --- a/docs/gitbook/install/flagger-install-on-eks-appmesh.md +++ b/docs/gitbook/install/flagger-install-on-eks-appmesh.md @@ -133,11 +133,18 @@ Add Flagger Helm repository: helm repo add flagger https://flagger.app ``` +Install Flagger's Canary CRD: + +```yaml +kubectl apply -f https://raw.githubusercontent.com/weaveworks/flagger/master/artifacts/flagger/crd.yaml +``` + Deploy Flagger and Prometheus in the _**appmesh-system**_ namespace: ```bash helm upgrade -i flagger flagger/flagger \ --namespace=appmesh-system \ +--set crd.create=false \ --set meshProvider=appmesh \ --set prometheus.install=true ``` @@ -150,6 +157,7 @@ You can enable **Slack** notifications with: ```bash helm upgrade -i flagger flagger/flagger \ --namespace=appmesh-system \ +--set crd.create=false \ --set meshProvider=appmesh \ --set metricsServer=http://prometheus.appmesh:9090 \ --set slack.url=https://hooks.slack.com/services/YOUR/SLACK/WEBHOOK \ diff --git a/docs/gitbook/install/flagger-install-on-google-cloud.md b/docs/gitbook/install/flagger-install-on-google-cloud.md index 9f5a0011..e1a38452 100644 --- a/docs/gitbook/install/flagger-install-on-google-cloud.md +++ b/docs/gitbook/install/flagger-install-on-google-cloud.md @@ -354,11 +354,18 @@ Add Flagger Helm repository: helm repo add flagger https://flagger.app ``` +Install Flagger's Canary CRD: + +```yaml +kubectl apply -f https://raw.githubusercontent.com/weaveworks/flagger/master/artifacts/flagger/crd.yaml +``` + Deploy Flagger in the `istio-system` namespace with Slack notifications enabled: ```bash helm upgrade -i flagger flagger/flagger \ --namespace=istio-system \ +--set crd.create=false \ --set metricsServer=http://prometheus.istio-system:9090 \ --set slack.url=https://hooks.slack.com/services/YOUR/SLACK/WEBHOOK \ --set slack.channel=general \ diff --git a/docs/gitbook/install/flagger-install-on-kubernetes.md b/docs/gitbook/install/flagger-install-on-kubernetes.md index e03f48a4..8a4f6605 100644 --- a/docs/gitbook/install/flagger-install-on-kubernetes.md +++ b/docs/gitbook/install/flagger-install-on-kubernetes.md @@ -11,18 +11,18 @@ Flagger requires a Kubernetes cluster **v1.11** or newer with the following admi ### Install Flagger with Helm -Install Flagger's Canary CRD: - -```yaml -kubectl apply -f https://raw.githubusercontent.com/weaveworks/flagger/master/artifacts/flagger/crd.yaml -``` - Add Flagger Helm repository: ```bash helm repo add flagger https://flagger.app ``` +Install Flagger's Canary CRD: + +```yaml +kubectl apply -f https://raw.githubusercontent.com/weaveworks/flagger/master/artifacts/flagger/crd.yaml +``` + Deploy Flagger for Istio: ```bash diff --git a/docs/gitbook/install/flagger-install-with-supergloo.md b/docs/gitbook/install/flagger-install-with-supergloo.md index 7ec10ed1..591de8df 100644 --- a/docs/gitbook/install/flagger-install-with-supergloo.md +++ b/docs/gitbook/install/flagger-install-with-supergloo.md @@ -115,11 +115,18 @@ Add Flagger Helm repository: helm repo add flagger https://flagger.app ``` +Install Flagger's Canary CRD: + +```yaml +kubectl apply -f https://raw.githubusercontent.com/weaveworks/flagger/master/artifacts/flagger/crd.yaml +``` + Deploy Flagger in the _**istio-system**_ namespace and set the service mesh provider to SuperGloo: ```bash helm upgrade -i flagger flagger/flagger \ --namespace=istio-system \ +--set crd.create=false \ --set metricsServer=http://prometheus.istio-system:9090 \ --set meshProvider=supergloo:istio.supergloo-system ``` From ece5c4401ea529b199b13df7d86eca998f8ffb1b Mon Sep 17 00:00:00 2001 From: stefanprodan Date: Sat, 27 Jul 2019 14:45:49 +0300 Subject: [PATCH 08/12] Make installer work with Kustomize v3 --- kustomize/base/flagger/deployment.yaml | 1 - kustomize/tester/deployment.yaml | 8 -------- kustomize/tester/service.yaml | 2 +- 3 files changed, 1 insertion(+), 10 deletions(-) diff --git a/kustomize/base/flagger/deployment.yaml b/kustomize/base/flagger/deployment.yaml index 17bcc3b2..ab02b0e8 100644 --- a/kustomize/base/flagger/deployment.yaml +++ b/kustomize/base/flagger/deployment.yaml @@ -2,7 +2,6 @@ apiVersion: apps/v1 kind: Deployment metadata: name: flagger - namespace: flagger-system spec: replicas: 1 strategy: diff --git a/kustomize/tester/deployment.yaml b/kustomize/tester/deployment.yaml index 8e7a117f..090785a0 100644 --- a/kustomize/tester/deployment.yaml +++ b/kustomize/tester/deployment.yaml @@ -57,11 +57,3 @@ spec: securityContext: readOnlyRootFilesystem: true runAsUser: 10001 -# volumeMounts: -# - name: tests -# mountPath: /bats -# readOnly: true -# volumes: -# - name: tests -# configMap: -# name: flagger-loadtester-bats \ No newline at end of file diff --git a/kustomize/tester/service.yaml b/kustomize/tester/service.yaml index 772b20af..0093b319 100644 --- a/kustomize/tester/service.yaml +++ b/kustomize/tester/service.yaml @@ -12,4 +12,4 @@ spec: - name: http port: 80 protocol: TCP - targetPort: http \ No newline at end of file + targetPort: http From 0648d81d3446d1bf24629bed286974fbdb2f0e27 Mon Sep 17 00:00:00 2001 From: stefanprodan Date: Sat, 27 Jul 2019 14:49:57 +0300 Subject: [PATCH 09/12] Use Kustomize for Istio e2e testing --- test/e2e-istio.sh | 4 +--- test/e2e-tests.sh | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/test/e2e-istio.sh b/test/e2e-istio.sh index 1ab10fb6..1043d3f9 100755 --- a/test/e2e-istio.sh +++ b/test/e2e-istio.sh @@ -26,9 +26,7 @@ echo '>>> Load Flagger image in Kind' kind load docker-image test/flagger:latest echo '>>> Installing Flagger' -helm upgrade -i flagger ${REPO_ROOT}/charts/flagger \ ---namespace istio-system \ ---set meshProvider=istio +kubectl apply -k ${REPO_ROOT}/kustomize/istio kubectl -n istio-system set image deployment/flagger flagger=test/flagger:latest kubectl -n istio-system rollout status deployment/flagger \ No newline at end of file diff --git a/test/e2e-tests.sh b/test/e2e-tests.sh index 829fcf57..df5797d8 100755 --- a/test/e2e-tests.sh +++ b/test/e2e-tests.sh @@ -13,7 +13,7 @@ kubectl create namespace test kubectl label namespace test istio-injection=enabled echo '>>> Installing the load tester' -kubectl -n test apply -f ${REPO_ROOT}/artifacts/loadtester/ +kubectl apply -k ${REPO_ROOT}/kustomize/tester kubectl -n test rollout status deployment/flagger-loadtester echo '>>> Initialising canary' From e3f8bff6fc4023ee65b3c13178cfcd31b40fd4c2 Mon Sep 17 00:00:00 2001 From: stefanprodan Date: Sat, 27 Jul 2019 15:10:45 +0300 Subject: [PATCH 10/12] Add Kustomize download link to docs --- .../install/flagger-install-on-kubernetes.md | 22 +++++++++++---- kustomize/README.md | 27 ++++++++++++++----- 2 files changed, 37 insertions(+), 12 deletions(-) diff --git a/docs/gitbook/install/flagger-install-on-kubernetes.md b/docs/gitbook/install/flagger-install-on-kubernetes.md index 8a4f6605..5800e50f 100644 --- a/docs/gitbook/install/flagger-install-on-kubernetes.md +++ b/docs/gitbook/install/flagger-install-on-kubernetes.md @@ -135,32 +135,44 @@ kubectl -n istio-system port-forward svc/flagger-grafana 3000:80 ### Install Flagger with Kustomize As an alternative to Helm, Flagger can be installed with Kustomize. -Note that you'll need kubectl 1.14 or newer that comes with the Kustomize commands. **Service mesh specific installers** Install Flagger for Istio: ```bash -kubectl apply -k github.com/weaveworks/flagger/kustomize/istio +kubectl apply -k github.com/weaveworks/flagger//kustomize/istio ``` This deploys Flagger in the `istio-system` namespace and sets the metrics server URL to Istio's Prometheus instance. +Note that you'll need kubectl 1.14 to run the above the command or you can download the +[kustomize binary](https://github.com/kubernetes-sigs/kustomize/releases) and run: + +```bash +kustomize build github.com/weaveworks/flagger//kustomize/istio | kubectl apply -f - +``` + Install Flagger for Linkerd: ```bash -kubectl apply -k github.com/weaveworks/flagger/kustomize/linkerd +kubectl apply -k github.com/weaveworks/flagger//kustomize/linkerd ``` This deploys Flagger in the `linkerd` namespace and sets the metrics server URL to Linkerd's Prometheus instance. +If you want to install a specific Flagger release, add the version number to the URL: + +```bash +kubectl apply -k github.com/weaveworks/flagger//kustomize/linkerd?ref=0.18.0 +``` + **Generic installer** Install Flagger and Prometheus: ```bash -kubectl apply -k github.com/weaveworks/flagger/kustomize/kubernetes +kubectl apply -k github.com/weaveworks/flagger//kustomize/kubernetes ``` This deploys Flagger and Prometheus in the `flagger-system` namespace, @@ -178,7 +190,7 @@ metadata: name: app namespace: test spec: - # can be: kubernetes, istio, appmesh, linkerd, smi, nginx, gloo, supergloo + # can be: kubernetes, istio, linkerd, appmesh, nginx, gloo # use the kubernetes provider for Blue/Green style deployments provider: nginx ``` diff --git a/kustomize/README.md b/kustomize/README.md index 3349364c..b9bdf981 100644 --- a/kustomize/README.md +++ b/kustomize/README.md @@ -1,7 +1,6 @@ # Flagger Kustomize installer As an alternative to Helm, Flagger can be installed with [Kustomize](https://kustomize.io/). -Note that you'll need kubectl 1.14 or newer that comes with the Kustomize commands. ## Service mesh specific installers @@ -11,7 +10,14 @@ Install Flagger for Istio: kubectl apply -k github.com/weaveworks/flagger//kustomize/istio ``` -This deploys Flagger in the `istio-system` namespace and sets the metrics server URL to `http://prometheus.istio-system:9090`. +This deploys Flagger in the `istio-system` namespace and sets the metrics server URL to Istio's Prometheus instance. + +Note that you'll need kubectl 1.14 to run the above the command or you can download the +[kustomize binary](https://github.com/kubernetes-sigs/kustomize/releases) and run: + +```bash +kustomize build github.com/weaveworks/flagger//kustomize/istio | kubectl apply -f - +``` Install Flagger for Linkerd: @@ -19,7 +25,13 @@ Install Flagger for Linkerd: kubectl apply -k github.com/weaveworks/flagger//kustomize/linkerd ``` -This deploys Flagger in the `linkerd` namespace and sets the metrics server URL to `http://linkerd-prometheus.linkerd:9090`. +This deploys Flagger in the `linkerd` namespace and sets the metrics server URL to Linkerd's Prometheus instance. + +If you want to install a specific Flagger release, add the version number to the URL: + +```bash +kubectl apply -k github.com/weaveworks/flagger//kustomize/linkerd?ref=0.18.0 +``` ## Generic installer @@ -32,9 +44,6 @@ kubectl apply -k github.com/weaveworks/flagger//kustomize/kubernetes This deploys Flagger and Prometheus in the `flagger-system` namespace, sets the metrics server URL to `http://flagger-prometheus.flagger-system:9090` and the mesh provider to `kubernetes`. -The Prometheus instance has a two hours data retention and is configured to scrape all pods in your cluster that -have the `prometheus.io/scrape: "true"` annotation. - To target a different provider you can specify it in the canary custom resource: ```yaml @@ -44,11 +53,15 @@ metadata: name: app namespace: test spec: - # can be: kubernetes, appmesh, nginx, gloo + # can be: kubernetes, istio, linkerd, appmesh, nginx, gloo # use the kubernetes provider for Blue/Green style deployments provider: nginx ``` +You'll need Prometheus when using Flagger with AWS App Mesh, Gloo or NGINX ingress controller. +The Prometheus instance has a two hours data retention and is configured to scrape all pods in your cluster that +have the `prometheus.io/scrape: "true"` annotation. + ## Configure Slack notifications Create a kustomization file using flagger as base: From dab3d53b653795054bbfaca07906798a016e15dd Mon Sep 17 00:00:00 2001 From: stefanprodan Date: Sun, 28 Jul 2019 11:28:00 +0300 Subject: [PATCH 11/12] Disable supergloo e2e --- .circleci/config.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index b5fbad2d..7e19e332 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -148,9 +148,9 @@ workflows: - e2e-smi-istio-testing: requires: - build-binary - - e2e-supergloo-testing: - requires: - - build-binary +# - e2e-supergloo-testing: +# requires: +# - build-binary - e2e-gloo-testing: requires: - build-binary @@ -165,7 +165,7 @@ workflows: - build-binary - e2e-istio-testing - e2e-smi-istio-testing - - e2e-supergloo-testing + #- e2e-supergloo-testing - e2e-gloo-testing - e2e-nginx-testing - e2e-linkerd-testing From 9e33a116d47ca576ff34535a442ca9fad1999084 Mon Sep 17 00:00:00 2001 From: stefanprodan Date: Mon, 29 Jul 2019 11:33:28 +0300 Subject: [PATCH 12/12] Add manual gating link to readme --- README.md | 1 + docs/gitbook/how-it-works.md | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 3279e711..a598f509 100644 --- a/README.md +++ b/README.md @@ -35,6 +35,7 @@ Flagger documentation can be found at [docs.flagger.app](https://docs.flagger.ap * [Custom metrics](https://docs.flagger.app/how-it-works#custom-metrics) * [Webhooks](https://docs.flagger.app/how-it-works#webhooks) * [Load testing](https://docs.flagger.app/how-it-works#load-testing) + * [Manual gating](https://docs.flagger.app/how-it-works#manual-gating) * [FAQ](https://docs.flagger.app/faq) * Usage * [Istio canary deployments](https://docs.flagger.app/usage/progressive-delivery) diff --git a/docs/gitbook/how-it-works.md b/docs/gitbook/how-it-works.md index 829a2c41..bc41d51b 100644 --- a/docs/gitbook/how-it-works.md +++ b/docs/gitbook/how-it-works.md @@ -910,7 +910,7 @@ Change the URL to `/gate/approve` to start the canary analysis: ```yaml canaryAnalysis: webhooks: - - name: "start gate" + - name: "gate" type: confirm-rollout url: http://flagger-loadtester.test/gate/approve ``` @@ -920,7 +920,7 @@ Manual gating can be driven with Flagger's tester API. Set the confirmation URL ```yaml canaryAnalysis: webhooks: - - name: "ask confirmation" + - name: "ask for confirmation" type: confirm-rollout url: http://flagger-loadtester.test/gate/check ```