Sprint 06
Todo
Todo:
✔️ Create the development branch ✔️ Create the development Cloud Build YAML file ✔️ Create the Cloud Build trigger for the development branch ✔️ Create the development namespace ✔️ Push changes to development
Steps
-
Do a git pull for the main branch.
git checkout master
git pull -
Create a new branch.
git checkout -b development
git branch -
Update the Cloud Build YAML file.
-
Go to Cloud Build > Trigger > CREATE TRIGGER. Specify the following:
- Name: gcp-devops-project-dev
- Description: This is the Cloud Build trigger for the development branch.
- Event: Push to a branch
- Repository: gcp-devops-project
- Branch:
^development$ - Configuration: Cloud Build configuration file (yaml or json)
-
Go to GKE > Connect to your GKE cluster using Cloudshell. Create the namespace.
kubectl create ns gcp-devops-dev -
Update the gke.yaml to point the image and namespace to the correct one.
-
Push the change to Github.
git add .
git commit -m "Add deployment files for dev environment."
git push -
Go to Cloud Build to see the running job.
We should see all green check marks.
-
Back at the GKE console, go to Workloads > Namespace: gcp-devops-dev
Go to Services & Ingress > Namespace: gcp-devops-dev
Click the endpoint and verify that you can access the application.