Moving Pipeline [Canary Deployment ] to Git

This commit is contained in:
John Cult 2023-06-12 21:15:46 +05:30
parent d5cbf88d4c
commit 07b60be261
1 changed files with 75 additions and 0 deletions

75
.harness/Canar.yaml Normal file
View File

@ -0,0 +1,75 @@
pipeline:
name: "Canary Deployment "
identifier: Canar
projectIdentifier: BlueGreen_Deploy_Tutorial
orgIdentifier: default
tags: {}
stages:
- stage:
name: canary deploy
identifier: canary_deploy
description: ""
type: Deployment
spec:
deploymentType: Kubernetes
service:
serviceRef: harnessguestbook1
environment:
environmentRef: preprod
deployToAll: false
infrastructureDefinitions:
- identifier: kubs_infrast
execution:
steps:
- stepGroup:
name: Canary Deployment
identifier: canaryDepoyment
steps:
- step:
name: Canary Deployment
identifier: canaryDeployment
type: K8sCanaryDeploy
timeout: 10m
spec:
instanceSelection:
type: Count
spec:
count: 1
skipDryRun: false
- step:
name: Canary Delete
identifier: canaryDelete
type: K8sCanaryDelete
timeout: 10m
spec: {}
- stepGroup:
name: Primary Deployment
identifier: primaryDepoyment
steps:
- step:
name: Rolling Deployment
identifier: rollingDeployment
type: K8sRollingDeploy
timeout: 10m
spec:
skipDryRun: false
rollbackSteps:
- step:
name: Canary Delete
identifier: rollbackCanaryDelete
type: K8sCanaryDelete
timeout: 10m
spec: {}
- step:
name: Rolling Rollback
identifier: rollingRollback
type: K8sRollingRollback
timeout: 10m
spec: {}
tags: {}
failureStrategies:
- onFailure:
errors:
- AllErrors
action:
type: StageRollback