
11.Resolve Pod Deployment Issue
Lab Information A junior DevOps team member encountered difficulties deploying a stack on the Kubernetes cluster. The pod fails to start, presenting errors. Let's troubleshoot and rectify the issue promptly. There is a pod named webserver, and the container within it is named nginx-container, its utilizing the nginx:latest image. Additionally, there's a sidecar container named sidecar-container using the ubuntu:latest image. Identify and address the issue to ensure the pod is in the running state and the application is accessible. Note: The kubectl utility on jump_host is configured to interact with the Kubernetes cluster. Lab Solutions Step 1: Check the current pod status and details kubectl get pods kubectl describe pod webserver kubectl delete pod webserver # Create a corrected pod definition cat > webserver-fixed.yaml <<EOF apiVersion: v1 kind: Pod metadata: name: webserver labels: app: web-app spec: containers: - name: nginx-container image: nginx:latest # Fixed: removed extra 's'
Continue reading on Dev.to
Opens in a new tab



