Skip to main content

Task 01: Commit and Push Configuration

Objective: Commit configuration changes and push to the repository to trigger CI/CD pipeline

DOCUMENT CATEGORY: Runbook SCOPE: Commit Terraform configuration to Git and trigger pipeline PURPOSE: Commit Terraform configuration to Git and trigger pipeline MASTER REFERENCE: Azure Pipelines Documentation

Status: Active

Procedure​

1. Review Changes​

cd /path/to/project
git status
git diff terraform.tfvars

2. Stage Changes​

git add terraform.tfvars
git add terraform/ # If using separate terraform directory

3. Commit with Descriptive Message​

git commit -m "Deploy Phase 04 management infrastructure

- Configure management mode with VNet 10.100.1.0/24
- Configure cluster c01 at RAL location
- Deploy VPN Gateway VpnGw2AZ with BGP
- Enable Azure Bastion and Key Vault
"

4. Push to Repository​

git push origin main

Pipeline will automatically trigger on push.


Validation​

  • Git commit successful
  • Changes pushed to repository
  • Pipeline automatically started in CI/CD pipeline → Pipelines


When to use: Use this tab if your CI/CD pipeline runs on GitHub Actions.

See procedure steps above for GitHub-specific guidance.

Toolkit Reference

Scripts for this task are located in the azurelocal-toolkit repository under scripts/deploy/ in the appropriate task folder.


Alternatives​

The procedures in this task use the methods shown in the tabs above. The toolkit is PowerShell 7 only and has no Bash scripts. A few tasks that act on Azure also have an Azure CLI script written in PowerShell. The script status page of the toolkit lists which task has which script.

PreviousUpNext
Phase 01 - ConfigurationPhase 02 - ExecutionTask 02 - Validate Stage

Values from infrastructure.yml​

The pipeline settings are in the devops section of infrastructure.yml (schema 5): the platform, the project, the repository, the approval environments, the runners and the Terraform state. The Terraform code does not define these values a second time. config/variables/scripts/New-IacVariableFiles.ps1 writes terraform.tfvars.json and backend.hcl from the file. See the variables reference.


Troubleshooting​

IssueCauseResolution
Push rejected by remoteBranch protection rules blocking pushCreate a pull request instead of direct push
Commit fails pre-commit hooksConfiguration files failing validationFix validation errors reported by pre-commit hooks

Version Control​

VersionDateAuthorChanges
1.0.02026-03-24Azure Local CloudInitial release