Forum Discussion
rafaelfholanda
Jun 26, 2023Copper Contributor
AKS Environments and Release Pipeline
Is it possible to reconcile deployment environments with release pipelines?
In release pipelines is it possible to use the parameter "environment:" in yaml?
1 Reply
Sort By
In Azure DevOps YAML pipelines, the environment: keyword allows us to define where your deployment happens and enables features like:
- Traceability between pipeline runs and deployed resources
- Approval gates before deployment
- Resource monitoring (especially for AKS)
Sample:
jobs: - deployment: DeployToAKS environment: 'aks-prod.default' strategy: runOnce: deploy: steps: - task: KubernetesManifest@0 inputs: action: deploy namespace: default manifests: | $(Pipeline.Workspace)/manifests/deployment.yml $(Pipeline.Workspace)/manifests/service.yml
aks-prod.default refers to an environment named aks-prod with a Kubernetes namespace default.