I deployed the manifests in lab1_volume_begin exercise on Minikube running on Ubuntu WSL2 (not on Docker Desktop) on Windows but that didn't work.
Now I am trying to deploy the manifests on CentOS 7 VM running on GCP but I still see it's not working.
$ kubectl version --short
Client Version: v1.25.2
Kustomize Version: v4.5.7
Server Version: v1.25.2
In the current set up on CentOS 7, when I check the logs, the backend pod is failing.
[tom@master yaml]$ kubectl get pod,ing,svc
NAME READY STATUS RESTARTS AGE
pod/docker-registry-pod 1/1 Running 2 (3h3m ago) 42h
pod/guestbook-backend-558f7f9bc6-rtbvr 0/1 CrashLoopBackOff 9 (3m21s ago) 30m
pod/guestbook-database-69bfdf8875-vqxwx 1/1 Running 0 152m
pod/guestbook-frontend-65694b489f-8qc2m 1/1 Running 0 152m
NAME CLASS HOSTS ADDRESS PORTS AGE
ingress.networking.k8s.io/guestbook-guestbook-ingress <none> guestbook.frontend.minikube.local,guestbook.backend.minikube.local 80 36m
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
service/guestbook-backend ClusterIP 10.97.254.212 <none> 80/TCP 152m
service/guestbook-database ClusterIP 10.106.67.122 <none> 27017/TCP 152m
service/guestbook-frontend ClusterIP 10.109.167.16 <none> 80/TCP 152m
service/kubernetes ClusterIP 10.96.0.1 <none> 443/TCP 2d
[tom@master yaml]$ pwd
/home/tom/kubernetes_storage/lab1_volume_begin/yaml
[tom@master yaml]$ kubectl logs --previous --tail 10 pod/guestbook-backend-558f7f9bc6-rtbvr
Guestbook API listening on port 3000 ..
/home/node/app/node_modules/mongodb/lib/utils.js:691
throw error;
^
MongoServerSelectionError: getaddrinfo EAI_AGAIN guestbook-database:27017
at Timeout.waitQueueMember.timer.setTimeout [as _onTimeout] (/home/node/app/node_modules/mongodb/lib/core/sdam/topology.js:439:30)
at ontimeout (timers.js:498:11)
at tryOnTimeout (timers.js:323:5)
at Timer.listOnTimeout (timers.js:290:5)
I have been trying to get this work for the last two days. I will really appreciate any help.
I deployed the manifests in
lab1_volume_beginexercise on Minikube running on Ubuntu WSL2 (not on Docker Desktop) on Windows but that didn't work.Now I am trying to deploy the manifests on CentOS 7 VM running on GCP but I still see it's not working.
In the current set up on CentOS 7, when I check the logs, the backend pod is failing.
I have been trying to get this work for the last two days. I will really appreciate any help.