geerlingguy / kubernetes-101

Kubernetes 101 - by Jeff Geerling
https://kube101.jeffgeerling.com/
MIT License
555 stars 166 forks source link

geerlingguy/kube101:hello-go-v2 crashes #31

Open t2d opened 3 years ago

t2d commented 3 years ago

Chapter 3 - "Updating the Go App"

❯ kubectl get pods
NAME                        READY   STATUS    RESTARTS   AGE
hello-go-57db6d78c7-6nvwj   1/1     Running   0          88m
hello-go-57db6d78c7-tcdjw   1/1     Running   0          86m
hello-go-57db6d78c7-zrmqq   1/1     Running   0          86m

❯ kubectl set image deployment/hello-go kube101=geerlingguy/kube101:hello-go-v2
deployment.apps/hello-go image updated

❯ kubectl get pods
NAME                        READY   STATUS             RESTARTS   AGE
hello-go-57db6d78c7-6nvwj   1/1     Running            0          88m
hello-go-57db6d78c7-tcdjw   1/1     Running            0          87m
hello-go-57db6d78c7-zrmqq   1/1     Running            0          86m
hello-go-69c8fd4b66-khd89   0/1     CrashLoopBackOff   1          7s

❯ kubectl rollout undo deployment hello-go
deployment.apps/hello-go rolled back

❯ kubectl get pods
NAME                        READY   STATUS    RESTARTS   AGE
hello-go-57db6d78c7-6nvwj   1/1     Running   0          88m
hello-go-57db6d78c7-tcdjw   1/1     Running   0          87m
hello-go-57db6d78c7-zrmqq   1/1     Running   0          86m

Log only shows: [pod/hello-go-69c8fd4b66-hddqv/kube101] standard_init_linux.go:219: exec user process caused: exec format error

geerlingguy commented 3 years ago

Hmm... I wonder if maybe I only built an arm64 version of the image. I need to build it for Intel/ARM.

nqb commented 2 years ago

I got same behaviour here.