conventions.io

Tech Challenge

2026-08-31

☸️

Daily Tech Challenge

Kubernetes

medium
Question 1 of 5

You are about to ship a change and want to see exactly what it would do to the live cluster first. You run the command below against a cluster that also has a mutating webhook injecting a sidecar. What does kubectl diff actually do, and what does it exit with?

Example
$ kubectl diff -f deploy.yaml
diff -u -N /tmp/LIVE-1/apps.v1.Deployment.prod.web /tmp/MERGED-2/apps.v1.Deployment.prod.web
--- /tmp/LIVE-1/...
+++ /tmp/MERGED-2/...
@@ -32,7 +32,7 @@
-        image: web:1.4
+        image: web:1.5
$ echo $?

Monday, August 31, 2026 · A new challenge drops every day