Application Design and Build: CKAD practice questions

Application Design and Build is 20% of the free CKAD mock (10 of 50 questions). Pick an answer to see right away whether it is correct, with the explanation and the documentation section it comes from.

CK.I · CKAD practice question

A container needs temporary working storage that can spill onto disk if memory pressure occurs, without using a network PersistentVolume. Which volume configuration fits best?

Choose one answer
Check answer and explanation

Correct answer: emptyDir with medium: '' (default disk/node storage) and an optional sizeLimit

Explanation

Default emptyDir storage uses the node's ephemeral storage (such as disk) and supports sizeLimit to cap usage per Pod without requiring external network storage.

Common trap

Default emptyDir storage uses the node's ephemeral storage (such as disk) and supports sizeLimit to cap usage per Pod without requiring external network storage.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

A CronJob named daily-compact has startingDeadlineSeconds: 60 and schedule: '0 1 * * *'. What happens if the cluster control plane is unavailable from 01:00 to 01:05 and recovers at 01:05?

Choose one answer
Check answer and explanation

Correct answer: The missed run is not started because the recovery time exceeds startingDeadlineSeconds

Explanation

If a scheduled start time is missed and the number of seconds since the missed schedule exceeds startingDeadlineSeconds, Kubernetes treats the run as missed and does not start it.

Common trap

If a scheduled start time is missed and the number of seconds since the missed schedule exceeds startingDeadlineSeconds, Kubernetes treats the run as missed and does not start it.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

A Job has completions: 6, parallelism: 2, and completionMode: Indexed. What environment variable does each Pod receive to identify its work index from 0 to 5?

Choose one answer
Check answer and explanation

Correct answer: JOB_COMPLETION_INDEX

Explanation

For an Indexed Job, Kubernetes injects JOB_COMPLETION_INDEX into each created Pod with its integer index in [0, completions - 1].

Common trap

For an Indexed Job, Kubernetes injects JOB_COMPLETION_INDEX into each created Pod with its integer index in [0, completions - 1].

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

A Pod has two initContainers (init-schema then init-seed) and one app container. If init-seed fails with exit code 1 on a Pod whose restartPolicy is Never, what happens to the Pod?

Choose one answer
Check answer and explanation

Correct answer: The Pod enters Failed phase and does not restart init-seed

Explanation

When a Pod has restartPolicy: Never and an initContainer fails, the container is not restarted and the Pod transitions to Failed.

Common trap

When a Pod has restartPolicy: Never and an initContainer fails, the container is not restarted and the Pod transitions to Failed.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

A Pod must mount a ConfigMap named feature-flags so each key in the ConfigMap appears as a separate file under /etc/config, and the container must NOT fail to start if feature-flags is temporarily absent. Which field enables that behavior?

Choose one answer
Check answer and explanation

Correct answer: configMap.optional: true

Explanation

Setting optional: true on a ConfigMap (or Secret) volume or env reference allows the Pod to start even if the referenced object does not exist yet.

Common trap

Setting optional: true on a ConfigMap (or Secret) volume or env reference allows the Pod to start even if the referenced object does not exist yet.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

A Pod runs a main web container and a traditional log-rotator sidecar in spec.containers, sharing an emptyDir volume mounted at /var/log/app. How should you configure that sidecar so it runs continuously alongside the main container and stops cleanly when the Pod terminates?

Choose one answer
Check answer and explanation

Correct answer: Define it in spec.containers with restartPolicy: Always

Explanation

A traditional sidecar that should run concurrently for the full lifetime of the Pod is defined in spec.containers with restartPolicy: Always so kubelet manages and terminates it with the Pod. Kubernetes also supports native sidecar containers via initContainers with restartPolicy: Always; this item asks for the traditional spec.containers form, not the native initContainers sidecar.

Common trap

A traditional sidecar that should run concurrently for the full lifetime of the Pod is defined in spec.containers with restartPolicy: Always so kubelet manages and terminates it with the Pod.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

A StatefulSet named ledger has replicas: 3 and a headless Service named ledger-headless. What is the predictable DNS name of the second Pod (ordinal 1) in namespace finance?

Choose one answer
Check answer and explanation

Correct answer: ledger-1.ledger-headless.finance.svc.cluster.local

Explanation

StatefulSet Pods get deterministic network identities in the form ...svc.cluster.local, which for ordinal 1 is ledger-1.ledger-headless.finance.svc.cluster.local.

Common trap

StatefulSet Pods get deterministic network identities in the form ...svc.cluster.local, which for ordinal 1 is ledger-1.ledger-headless.finance.svc.cluster.local.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

When a Pod with a PersistentVolumeClaim is deleted, when is the underlying PersistentVolume released and reclaimed according to its reclaim policy?

Choose one answer
Check answer and explanation

Correct answer: After the Pod terminates and the PVC is deleted (if no other Pod uses the PVC)

Explanation

A PVC remains bound while in use, and once released (after Pod release and PVC deletion), the PV's reclaimPolicy (Retain, Delete, or Recycle) determines cleanup.

Common trap

A PVC remains bound while in use, and once released (after Pod release and PVC deletion), the PV's reclaimPolicy (Retain, Delete, or Recycle) determines cleanup.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

Which container image tag practice is most reliable for reproducible production deployments in Kubernetes manifests?

Choose one answer
Check answer and explanation

Correct answer: Pinning an explicit immutable version tag or image digest

Explanation

Pinning an explicit immutable tag or digest ensures deterministic rollouts, rollbacks, and auditability across nodes and restarts.

Common trap

Pinning an explicit immutable tag or digest ensures deterministic rollouts, rollbacks, and auditability across nodes and restarts.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

Which cron expression in a CronJob spec runs a task every Sunday at 04:30 UTC?

Choose one answer
Check answer and explanation

Correct answer: 30 4 * * 0

Explanation

Standard five-field cron syntax is minute hour day-of-month month day-of-week, so 30 4 * * 0 runs at 04:30 on Sunday (day 0).

Common trap

Standard five-field cron syntax is minute hour day-of-month month day-of-week, so 30 4 * * 0 runs at 04:30 on Sunday (day 0).

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

Which ephemeral volume type provides a fresh empty directory scoped strictly to a single Pod's lifetime and disappears when the Pod is deleted or rescheduled?

Choose one answer
Check answer and explanation

Correct answer: emptyDir

Explanation

An emptyDir volume is created when a Pod is assigned to a node and exists only while that Pod runs on that node, making it ideal for scratch space or shared container data.

Common trap

An emptyDir volume is created when a Pod is assigned to a node and exists only while that Pod runs on that node, making it ideal for scratch space or shared container data.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

Which field in a StatefulSet defines the PVC template automatically provisioned for each replica?

Choose one answer
Check answer and explanation

Correct answer: spec.volumeClaimTemplates

Explanation

StatefulSet uses spec.volumeClaimTemplates to generate dedicated PersistentVolumeClaims per ordinal replica (such as data-web-0, data-web-1).

Common trap

StatefulSet uses spec.volumeClaimTemplates to generate dedicated PersistentVolumeClaims per ordinal replica (such as data-web-0, data-web-1).

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

Which field inside a Pod's downwardAPI volume allows a container to read its own assigned Pod IP address from a file without querying the Kubernetes API?

Choose one answer
Check answer and explanation

Correct answer: fieldRef: { fieldPath: status.podIP }

Explanation

In a downwardAPI volume item, fieldRef with fieldPath: status.podIP exposes the Pod's IP address into a mounted file inside the container.

Common trap

In a downwardAPI volume item, fieldRef with fieldPath: status.podIP exposes the Pod's IP address into a mounted file inside the container.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

Which imperative kubectl command generates a Pod YAML manifest named cache-pod using image redis:7.4 without creating the Pod in the cluster?

Choose one answer
Check answer and explanation

Correct answer: kubectl run cache-pod --image=redis:7.4 --dry-run=client -o yaml

Explanation

kubectl run with --image, --dry-run=client, and -o yaml outputs a client-validated Pod manifest to stdout without persisting it.

Common trap

kubectl run with --image, --dry-run=client, and -o yaml outputs a client-validated Pod manifest to stdout without persisting it.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

Which workload resource is best suited for a batch ETL job that processes a fixed queue of 500 partition keys using 4 parallel worker Pods and retries failed Pods up to 3 times per run?

Choose one answer
Check answer and explanation

Correct answer: Job with completions: 500, parallelism: 4, and backoffLimit: 3

Explanation

A Kubernetes Job runs Pods until a target completion count is reached, using parallelism to cap concurrent Pods and backoffLimit to cap retries on Pod failures.

Common trap

A Kubernetes Job runs Pods until a target completion count is reached, using parallelism to cap concurrent Pods and backoffLimit to cap retries on Pod failures.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

You are migrating a legacy workload on Kubernetes v1.37 that previously used an inline gitRepo volume. Which approach is recommended after the removal of the gitRepo volume driver?

Choose one answer
Check answer and explanation

Correct answer: Use an emptyDir volume populated by an initContainer or git-sync container

Explanation

Because the gitRepo volume driver was removed due to security risks, cloning repositories via an init container or sidecar/git-sync into an emptyDir volume is the standard pattern.

Common trap

Because the gitRepo volume driver was removed due to security risks, cloning repositories via an init container or sidecar/git-sync into an emptyDir volume is the standard pattern.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

You need to build an OCI container image from a Dockerfile that installs build tools in stage one and copies only the compiled Go binary into a minimal scratch base image in stage two. Which Dockerfile instruction copies the artifact from the first stage?

Choose one answer
Check answer and explanation

Correct answer: COPY --from=builder /app/server /server

Explanation

Multi-stage Docker builds use COPY --from= to transfer build artifacts from an earlier stage into a later stage while keeping final images small.

Common trap

Multi-stage Docker builds use COPY --from= to transfer build artifacts from an earlier stage into a later stage while keeping final images small.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

You need to pass a Pod's metadata.name and metadata.namespace as environment variables POD_NAME and POD_NAMESPACE into a container. Which env entry achieves this?

Choose one answer
Check answer and explanation

Correct answer: valueFrom: { fieldRef: { fieldPath: metadata.name } }

Explanation

Using env[].valueFrom.fieldRef with fieldPath: metadata.name (and metadata.namespace) injects Pod object fields directly into container environment variables.

Common trap

Using env[].valueFrom.fieldRef with fieldPath: metadata.name (and metadata.namespace) injects Pod object fields directly into container environment variables.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


CK.I · CKAD practice question

You want a Pod to run a setup script only once when created, even if the main application container restarts 10 times later. Which container section should hold the setup script?

Choose one answer
Check answer and explanation

Correct answer: spec.initContainers

Explanation

initContainers run to completion before any app container starts and are not re-executed every time an app container restarts.

Common trap

initContainers run to completion before any app container starts and are not re-executed every time an app container restarts.

Source: Original unofficial practice; not an official CKAD exam item
Checked against the cited text on 2026-11-30.

Report an error in this question

Open this question on its own page


Back to all topics