Change management has evolved given infrastructure is now API-driven. Traditionally ITIL change management required maintaining separate systems for compliance, but modern organizations leverage GitOps and infrastructure as code (IaC) tools to automate and streamline processes as demonstrated in this repo.
At DoiT International we advise cloud customers to implement modern change management using automated, self-documenting, processes as illustrated below.
Using this example assumes you have the following in place:
-
GCP Project
with billing enabled -
Project Editor
or above (i.e.Owner
) IAM role - Google Cloud SDK
- Knowledge of Terraform and GCP
# set config
gcloud config set project <project-id>
# clone repo (or fork it)
git clone [email protected]:doitintl/terraform-iac-demo.git
cd terraform-iac-demo
# reset git so you can push to your own repo
rm -rf .git
git init
# initialize project
./bin/setup.sh
You will need to create a Git source code repository and connect it to Google Cloud Build as instructed below. Connect Github repository to Cloud Build
Once you make sure you connect the repository for Cloud Build, and create a push trigger
, you can then commit
, set your remote
, and push
your code. This should trigger a build and Terraform tasks will run. See the document above (although dated and this repo is updated for later Terraform versions) for tips.
If you are just testing this functionality, to avoid incurring unnecessary cloud billing charges be sure to delete your project or follow these steps:
- edit
main.tf
in/prod
and/dev
folder and remove modules commit
andpush
changes to trigger infrastructure changes- run the
./bin/teardown.sh
after resources removed
This repository is maintained by the staff at DoiT International