Skip to content

Latest commit

 

History

History
53 lines (35 loc) · 845 Bytes

README.md

File metadata and controls

53 lines (35 loc) · 845 Bytes

Recreate

A deployment defined with a strategy of type Recreate will terminate all the running instances then recreate them with the newer version.

recreate

Go to the right directory

cd ~/Workshop-K8S/k8s/recreate/

Create namespace

kubectl create ns recreate

Deploy App v1

kubectl apply -n recreate -f app-v1.yaml

Test:

curl http://[public ip adress load balancer]/api

Or in browser: <http://[public ip adress load balancer]

Deploy App v2

kubectl apply -n recreate -f app-v2.yaml

Downtime is expected because v1 is killed before v2 is started and healthy:

curl http://[public ip adress load balancer]/api

Or in browser: <http://[public ip adress load balancer]

Clean up

kubectl delete ns recreate