Skip to content
CKADApplication Design and BuildSingle nodeMedium

CronJob with history limits and a manual run

Scenario ckad-des-004 · about 7 minutes · 9 points · 9 grader checks

Create a CronJob with concurrency and history settings, then trigger an immediate run from it.

  • cronjob
  • job
  • batch
  • schedule

What you will practise

  • Create a CronJob with a cron schedule
  • Set concurrencyPolicy and job history limits
  • Run a CronJob on demand with kubectl create job --from

Start this lab

With the CLI installed and signed in, this command provisions a single node cluster on your Mac, applies the scenario setup and prints the task below.

goldenkube start ckad-des-004

Task

The task text exactly as the CLI shows it. Solve it on the cluster, then run goldenkube submit.

In namespace "cron" (create it if it does not exist): 1. Create a CronJob named "reporter" that runs every 5 minutes (schedule "*/5 * * * *") with image busybox:1.36 and command: sh -c 'date; echo report' - a new run must not start while the previous one is still running - keep 2 successful and 1 failed finished Jobs in the history - the pod restart policy is OnFailure 2. Do not wait for the schedule: trigger one run now by creating a Job named "reporter-manual" from the CronJob "reporter". That Job must complete successfully.

Requirements and details

Certification
CKAD · Certified Kubernetes Application Developer
Domain
Application Design and Build
Difficulty
Medium
Cluster topology
Single node
Cluster features
None beyond the base cluster
Recommended time
7 minutes
Points
9
Grader checks
9
Kubernetes version
1.37
Minimum CLI version
0.1.0
Scenario version
1
Published

Grading runs locally: 9 state checks read your cluster when you submit; the scenario passes when every check passes. Hints, the reference solution and the check definitions are available only inside the CLI, not on this page.

CKADApplication Design and BuildMedium

Sidecar container sharing an emptyDir

Build a two-container Pod where a log-shipping sidecar reads a file the main container writes into a shared volume.

Single node · ~7 min · 8 points

  • multi-container
  • sidecar
  • emptydir
  • pod
  • volumes

goldenkube start ckad-des-001

CKADApplication Design and BuildEasy

Init container prepares content for nginx

Use an init container to write content into a shared volume before the main web container starts.

Single node · ~7 min · 9 points

  • init-container
  • multi-container
  • emptydir
  • pod

goldenkube start ckad-des-002

CKADApplication Design and BuildEasy

Job with completions, parallelism and limits

Create a batch Job that runs several completions in parallel with retry and deadline limits.

Single node · ~6 min · 8 points

  • job
  • batch
  • completions
  • parallelism

goldenkube start ckad-des-003

Independent community project, not affiliated with or endorsed by CNCF or The Linux Foundation. Lab results are practice feedback, not an exam score.