This is a complete pipeline demonstrating:
- Continuous integration process once a code is merged into the "main" branch of a project
- Building an image once the tests are done
- Deploying the image into Cloud Run Dev App
- Manually promoting it into Cloud Run Prod App
- cloudbuild.yaml holds the CI pipeline steps
- clouddeploy.yaml holds the CD pipeline steps
- Create a Cloud Build Trigger:
- Using Cloud Console
- OR using command line:
gcloud beta builds triggers create github --repo-name clouddeploy-cloudrun-sample --repo-owner bijukunjummen --branch-pattern '^main$' --name clouddeploy-cloudrun-sample --build-config cloudbuild.yaml
- Create a Deployment Pipeline -
gcloud deploy apply --file=clouddeploy.yaml --region=us-west1