This is sample for Full Automation CI/CD with the Cloud Build of GCP. You need to use the Cloud Build
- Create GKE Cluster for each a environment on GCP
- develop cluster-name : dev-cb-sample-server
- staging cluster-name : stg-cb-sample-server
- product cluster-name : prd-cb-sample-server
- Fork or Clone devops repository the cb-sample-server-devops
- You need to setup kms for cb-sample-server-devops
- You need to rewrite that 'id: Decrypt ssh key' and 'id: Set rsa file' part of cloudbuild.yaml, dev.cloudbuild.yaml
- You need to set your devops repository url of github on cloudbuild.yaml, dev.cloudbuild.yaml
- Create Trigger of Docker image build for Push to branch(develop, staging, master) of source repository on Cloud Build.
- Cloud Build trigger setup for develop : dev.cloudbuild.yaml
- Cloud Build trigger setup for staging, product : cloudbuild.yaml
- Install golang
- Install Docker
- Init(Need to run first this) : make init
- Build : make build
- Run App on Local Docker : make docker-build