Bird
0
0

Given this Kubernetes Pod spec snippet using a ConfigMap:

medium📝 Command Output Q13 of 15
Kubernetes - ConfigMaps
Given this Kubernetes Pod spec snippet using a ConfigMap:
envFrom:
- configMapRef:
name: app-config

What happens if you update the ConfigMap 'app-config' while the Pod is running?
AThe Pod crashes immediately.
BThe Pod automatically reloads the new configuration without restart.
CThe Pod continues using the old configuration until restarted.
DThe Pod deletes the ConfigMap.
Step-by-Step Solution
Solution:
  1. Step 1: Understand envFrom with ConfigMap

    Using envFrom loads ConfigMap data as environment variables at Pod start.
  2. Step 2: Effect of ConfigMap update on running Pod

    Environment variables do not update dynamically; Pod must restart to see changes.
  3. Final Answer:

    The Pod continues using the old configuration until restarted. -> Option C
  4. Quick Check:

    Env vars from ConfigMap update only after Pod restart [OK]
Quick Trick: Env vars from ConfigMap update only after Pod restart [OK]
Common Mistakes:
  • Assuming automatic reload without restart
  • Thinking Pod crashes on ConfigMap change
  • Believing ConfigMap is deleted by Pod

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Kubernetes Quizzes