change harness directory name
+120 · 5 files changed
-
.harness/pipeline/container_pipeline.yml+58 −0 -
.harness/services/primary_container_deployment.yaml+21 −0 -
.harness/services/primary_service.yaml+10 −0 -
.harness/services/secondary_container_deployment.yaml+21 −0 -
.harness/services/secondary_service.yaml+10 −0
@@ -0,0 +1,58 @@ +pipeline: + name: container_pipeline + identifier: container_rolling_pipeline + projectIdentifier: default_project + orgIdentifier: default + tags: {} + stages: + - stage: + name: deploy-container + identifier: deploycontainer + description: "" + type: Deployment + spec: + deploymentType: Kubernetes + service: + serviceRef: harness_deploy_container + serviceInputs: + serviceDefinition: + type: Kubernetes + spec: + artifacts: + primary: + type: Acr + spec: + tag: <+input> + environment: + environmentRef: test + deployToAll: false + infrastructureDefinitions: + - identifier: harness_k8sinfra + execution: + steps: + - step: + name: Rollout Deployment + identifier: rolloutDeployment + type: K8sRollingDeploy + timeout: 10m + spec: + skipDryRun: false + pruningEnabled: false + delegateSelectors: + - kubernetes-delegate + rollbackSteps: + - step: + name: Rollback Rollout Deployment + identifier: rollbackRolloutDeployment + type: K8sRollingRollback + timeout: 10m + spec: + pruningEnabled: false + tags: {} + failureStrategies: + - onFailure: + errors: + - AllErrors + action: + type: StageRollback + @@ -0,0 +1,21 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: primary-container +spec: + replicas: 1 + revisionHistoryLimit: 3 + selector: + matchLabels: + app: primary-container + template: + metadata: + labels: + app: primary-container + spec: + containers: + - image: azacrkub.azurecr.io/primary_container:latest + name: primary-container + ports: + - containerPort: 12345 + @@ -0,0 +1,10 @@ +apiVersion: v1 +kind: Service +metadata: + name: primary-container +spec: + ports: + - port: 80 + targetPort: 12345 + selector: + app: primary-container @@ -0,0 +1,21 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: secondary-container +spec: + replicas: 1 + revisionHistoryLimit: 3 + selector: + matchLabels: + app: secondary-container + template: + metadata: + labels: + app: secondary-container + spec: + containers: + - image: azacrkub.azurecr.io/secondary_container:latest + name: secondary-container + ports: + - containerPort: 23456 + @@ -0,0 +1,10 @@ +apiVersion: v1 +kind: Service +metadata: + name: secondary-container +spec: + ports: + - port: 80 + targetPort: 12345 + selector: + app: secondary-container