0
0
Kubernetesdevops~10 mins

Why configuration separation matters in Kubernetes - Test Your Understanding

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to create a ConfigMap named 'app-config'.

Kubernetes
kubectl create configmap [1] --from-literal=key=value
Drag options to blanks, or click blank then click option'
Aconfig-app
Bapp-config
Cappconfig
Dconfigmap-app
Attempts:
3 left
💡 Hint
Common Mistakes
Using a name without a dash or incorrect order.
2fill in blank
medium

Complete the command to apply a ConfigMap from a file named 'config.yaml'.

Kubernetes
kubectl apply -f [1]
Drag options to blanks, or click blank then click option'
Aconfig.yaml
Bconfigmap.yaml
Cconfigmap.yml
Dconfig.yml
Attempts:
3 left
💡 Hint
Common Mistakes
Confusing '.yml' with '.yaml' or adding 'configmap' prefix.
3fill in blank
hard

Fix the error in the command to create a secret named 'db-secret' with a literal password.

Kubernetes
kubectl create secret generic [1] --from-literal=password=pass123
Drag options to blanks, or click blank then click option'
Adbsecret
Bdb.secret
Cdb-secret
Ddb_secret
Attempts:
3 left
💡 Hint
Common Mistakes
Using underscores or dots instead of dashes in names.
4fill in blank
hard

Fill both blanks to mount the ConfigMap 'app-config' as a volume named 'config-volume' in a pod spec.

Kubernetes
- name: [1]
  configMap:
    name: [2]
Drag options to blanks, or click blank then click option'
Aconfig-volume
Bapp-volume
Capp-config
Dconfigmap
Attempts:
3 left
💡 Hint
Common Mistakes
Mixing up volume name and ConfigMap name.
5fill in blank
hard

Fill both blanks to define environment variables from a ConfigMap named 'app-config' in a container spec.

Kubernetes
envFrom:
  - [1]:
    name: [2]
Drag options to blanks, or click blank then click option'
AconfigMapRef
BsecretRef
Capp-config
DconfigRef
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'secretRef' instead of 'configMapRef'.
Wrong field names.