Bird
0
0

How would you correctly define a feature flag named enableLogin set to true in a Kubernetes ConfigMap YAML?

easy📝 Syntax Q3 of 15
Kubernetes - Advanced Deployment Patterns
How would you correctly define a feature flag named enableLogin set to true in a Kubernetes ConfigMap YAML?
Aspec: enableLogin: true
Bdata: enableLogin: "true"
Cmetadata: enableLogin: true
Denv: - name: enableLogin value: true
Step-by-Step Solution
Solution:
  1. Step 1: Understand ConfigMap structure

    Feature flags go under the data section as key-value pairs.
  2. Step 2: Validate syntax

    data: enableLogin: "true" correctly uses data with string values.
  3. Final Answer:

    data: enableLogin: "true" -> Option B
  4. Quick Check:

    Feature flags are keys under data in ConfigMap [OK]
Quick Trick: Feature flags go under data section as strings [OK]
Common Mistakes:
  • Placing flags under spec or metadata
  • Using boolean true instead of string "true"
  • Confusing env variables with ConfigMap keys

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Kubernetes Quizzes