Skip to content

Instantly share code, notes, and snippets.

@JamesDLD
Last active November 13, 2019 12:48
Show Gist options
  • Save JamesDLD/757446e407ec0ca9e28aa165adbfb7cd to your computer and use it in GitHub Desktop.
Save JamesDLD/757446e407ec0ca9e28aa165adbfb7cd to your computer and use it in GitHub Desktop.
stages:
- stage: Build
jobs:
- job: Terraform_Plan
displayName: Terraform Plan - Publish a package if Infrastructure changes are identified
continueOnError: false
pool:
vmImage: $(vmImageName)
steps:
- task: DownloadSecureFile@1
displayName: "Download secure file $(backend_main_secret_file_id1)"
inputs:
secureFile: $(backend_main_secret_file_id1)
- template: terraform.yml@Yaml_Templates
parameters:
version: $(terraform_version)
path: "./AzureDevops-Introduction/aks-k8s/"
package_name: "aks-k8s"
terraform_init: true
terraform_plan: true
backend_secret_file_id: $(backend_main_secret_file_id1)
backend_file_path: "variable/backend-jdld.tfvars"
main_secret_file_id: $(backend_main_secret_file_id1)
main_file_path: "variable/main-jdld.tfvars"
- publish: "./ArtifactPublishLocation" # Local path to include in the Artifact
artifact: "$(artifact_name)"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment