Skip to content

Commit

Permalink
Add separate bluegreen-analysis folder so we can include files in wor…
Browse files Browse the repository at this point in the history
…kshop
  • Loading branch information
gnunn1 committed Oct 19, 2023
1 parent d2dc199 commit 438cdb0
Show file tree
Hide file tree
Showing 6 changed files with 98 additions and 24 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization

resources:
- analysistemplate.yaml
- rollout.yaml
- services.yaml
- routes.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
apiVersion: argoproj.io/v1alpha1
kind: Rollout
metadata:
name: rollouts-demo
spec:
replicas: 2
revisionHistoryLimit: 10
selector:
matchLabels:
app: rollouts-demo
strategy:
blueGreen:
activeService: active
previewService: preview
autoPromotionEnabled: false
prePromotionAnalysis:
args:
- name: query
value: irate%28haproxy_backend_http_responses_total%7Bexported_namespace%3D%27rollouts-demo-prod%27%2C%20route%3D~%22bluegreen-preview%22%2C%20code%3D%225xx%22%7D%5B1m%5D%29%20%3E%205%20or%20on%28%29%20vector%280%29
- name: route-url
value: bluegreen-preview-rollouts-demo-prod.${SUB_DOMAIN}
templates:
- templateName: smoke-tests
template:
metadata:
labels:
app: rollouts-demo
spec:
containers:
- image: quay.io/openshiftdemos/rollouts-demo:blue
imagePullPolicy: IfNotPresent
name: rollouts-demo
ports:
- containerPort: 8080
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
apiVersion: route.openshift.io/v1
kind: Route
metadata:
name: active
spec:
port:
targetPort: http
tls:
insecureEdgeTerminationPolicy: Redirect
termination: edge
to:
kind: Service
name: active
---
apiVersion: route.openshift.io/v1
kind: Route
metadata:
name: preview
spec:
port:
targetPort: http
tls:
insecureEdgeTerminationPolicy: Redirect
termination: edge
to:
kind: Service
name: preview
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
apiVersion: v1
kind: Service
metadata:
labels:
app: rollouts-demo
name: active
spec:
ports:
- port: 8080
protocol: TCP
targetPort: 8080
name: http
selector:
app: rollouts-demo
---
apiVersion: v1
kind: Service
metadata:
labels:
app: rollouts-demo
name: preview
spec:
ports:
- port: 8080
protocol: TCP
targetPort: 8080
name: http
selector:
app: rollouts-demo

This file was deleted.

0 comments on commit 438cdb0

Please sign in to comment.