Skip to content

Instantly share code, notes, and snippets.

Last active April 25, 2020 19:13
What would you like to do?
PCA Prep—Update and Scale Out a Containerized Application on a Kubernetes Cluster


I uploaded the src file via Cloud Shell

tar -xvzf echo-web-v2.tar.gz

docker build -t${PROJECT_ID}/echo-app:v2 .

docker push${PROJECT_ID}/echo-app:v2

Now you get 5 points

gcloud container clusters get-credentials echo-cluster --zone=us-central1-a

kubectl create deployment echo-web${PROJECT_ID}/echo-app:v2

Now you get 10 points

kubectl scale deployment echo-web --replicas=2

Now you get 15 points

kubectl expose deployment echo-web --type=LoadBalancer --port 80 --target-port 8000

Go to the Kunbernette Engine -> Services & Ingress -> Click Load balancer's endpoint (e.g.

Now you get 20 points

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment