Complete the code to rollback a deployment using Kubernetes command.
kubectl rollout [1] deployment/my-appThe correct command to rollback a deployment in Kubernetes is kubectl rollout rollback.
Complete the command to check the rollout status of a deployment.
kubectl rollout [1] deployment/my-appThe command kubectl rollout status shows the status of the deployment rollout.
Fix the error in the command to rollback to revision 2.
kubectl rollout rollback deployment/my-app --to-revision=[1]The correct syntax requires just the revision number, like --to-revision=2.
Fill both blanks to create a command that pauses and then resumes a deployment rollout.
kubectl rollout [1] deployment/my-app && kubectl rollout [2] deployment/my-app
First pause the rollout with pause, then resume it with resume.
Fill all three blanks to create a dictionary comprehension that filters failed updates and stores their revision numbers.
failed_updates = {rev[1]: status[2] for rev, status in updates.items() if status [3] 'failed'}The keys are named with _num, values with _code, and we filter where status equals 'failed'.