Created
August 21, 2020 04:19
-
-
Save mikesparr/35d07ea7357aa9cb230ae311325192cf to your computer and use it in GitHub Desktop.
Cloud Build CI example for custom Cloud DNS step
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# dynamically create DNS CNAME entry for review app | |
- name: 'gcr.io/cloud-builders/gcloud' | |
entrypoint: 'bash' | |
args: | |
- '-c' | |
- | | |
gcloud dns --project=devops-pipeline-demo record-sets transaction start --zone=msparr-com | |
gcloud dns --project=devops-pipeline-demo record-sets transaction add kong-proxy.msparr.com. \ | |
--name=demo-app-review-$_PR_NUMBER.msparr.com. \ | |
--ttl=300 \ | |
--type=CNAME \ | |
--zone=msparr-com | |
gcloud dns --project=devops-pipeline-demo record-sets transaction execute --zone=msparr-com |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment