loading...

Understanding Kubernetes: part 2 - CronJobs

aurelievache profile image Aurélie Vache Updated on ・1 min read

Understanding Kubernetes in sketchnotes (36 Part Series)

1) Understanding Kubernetes: part 1 – Pods 2) Understanding Kubernetes: part 2 - CronJobs 3 ... 34 3) Understanding Kubernetes: part 3 – Secrets 4) Understanding Kubernetes: part 4 – Namespaces & ResourceQuotas 5) Understanding Kubernetes: part 5 – Configmaps 6) Understanding Kubernetes: part 6 – Horizontal Pod Autoscaler 7) Understanding Kubernetes: part 7 – Services 8) Understanding Kubernetes: part 8 – Kubectl Tips 9) Understanding Kubernetes: part 9 – components : etcd, kubelet, scheduler... 10) Understanding Kubernetes: part 10 – Liveness & Readiness probes 11) Understanding Kubernetes: part 11 – Resources's Requests & Limits 12) Understanding Kubernetes: part 12 – Useful tools 13) Understanding Kubernetes: part 13 – Quality of Service 14) Understanding Kubernetes: part 14 – Persistent Volume, Persistent Volume Claim an Storage Class 15) Understanding Kubernetes: part 15 – Pod (Anti) Affinity and Node (Anti) Affinity 16) Understanding Kubernetes: part 16 – Useful tools - part 2 17) Understanding Kubernetes: part 17 – Useful tools - part 3 18) Understanding Kubernetes: part 18 – Network Policies 19) Understanding Kubernetes: part 19 – Useful tools - Kustomize tips 20) Understanding Kubernetes: part 20 – Pods pull images configuration 21) Understanding Kubernetes: part 21 – Useful tools - part 4 - security 22) Understanding Kubernetes: part 22 – LimitRange 23) Understanding Kubernetes: part 23 – Ingress 24) Understanding Kubernetes: part 24 – Node operations 25) Understanding Kubernetes: part 25 – Useful tools - part 5 - backup and restore with Velero 26) Understanding Kubernetes: part 26 – Deployment Rolling update 27) Understanding Kubernetes: part 27 – Jobs 28) Understanding Kubernetes: part 28 – Debugging/Troubleshooting Kubernetes 29) Understanding Kubernetes: part 29 – Pod lifecycle 30) Understanding Kubernetes: part 30 – Deployment 31) Understanding Kubernetes: part 31 – ReplicaSet 32) Understanding Kubernetes: part 32 – DaemonSet 33) Understanding Kubernetes: part 33 – Container lifecycle events 34) Understanding Kubernetes: part 34 – Kubeconfig file 35) Understanding Kubernetes: part 35 – Labels & Selectors 36) Understanding Kubernetes: part 36 – Pod deletion

Understanding Kubernetes can be difficult or time-consuming. In order to spread knowledges about Cloud technologies I started to create sketchnotes about Kubernetes. I think it could be a good way, more visual, to explain Kubernetes (and others technologies).

We continue the serie of Sketchnotes about Kubernetes with CronJobs.

Alt Text

If you are interested, I published all the sketchnotes on Kubernetes (and new ones!) to make a "book" of 120 pages: "Understanding Kubernetes in a visual way".

As usual, if you like theses sketchnotes, you can follow me, and tell me what do you think. I will publish others sketchs shortly :-).

Understanding Kubernetes in sketchnotes (36 Part Series)

1) Understanding Kubernetes: part 1 – Pods 2) Understanding Kubernetes: part 2 - CronJobs 3 ... 34 3) Understanding Kubernetes: part 3 – Secrets 4) Understanding Kubernetes: part 4 – Namespaces & ResourceQuotas 5) Understanding Kubernetes: part 5 – Configmaps 6) Understanding Kubernetes: part 6 – Horizontal Pod Autoscaler 7) Understanding Kubernetes: part 7 – Services 8) Understanding Kubernetes: part 8 – Kubectl Tips 9) Understanding Kubernetes: part 9 – components : etcd, kubelet, scheduler... 10) Understanding Kubernetes: part 10 – Liveness & Readiness probes 11) Understanding Kubernetes: part 11 – Resources's Requests & Limits 12) Understanding Kubernetes: part 12 – Useful tools 13) Understanding Kubernetes: part 13 – Quality of Service 14) Understanding Kubernetes: part 14 – Persistent Volume, Persistent Volume Claim an Storage Class 15) Understanding Kubernetes: part 15 – Pod (Anti) Affinity and Node (Anti) Affinity 16) Understanding Kubernetes: part 16 – Useful tools - part 2 17) Understanding Kubernetes: part 17 – Useful tools - part 3 18) Understanding Kubernetes: part 18 – Network Policies 19) Understanding Kubernetes: part 19 – Useful tools - Kustomize tips 20) Understanding Kubernetes: part 20 – Pods pull images configuration 21) Understanding Kubernetes: part 21 – Useful tools - part 4 - security 22) Understanding Kubernetes: part 22 – LimitRange 23) Understanding Kubernetes: part 23 – Ingress 24) Understanding Kubernetes: part 24 – Node operations 25) Understanding Kubernetes: part 25 – Useful tools - part 5 - backup and restore with Velero 26) Understanding Kubernetes: part 26 – Deployment Rolling update 27) Understanding Kubernetes: part 27 – Jobs 28) Understanding Kubernetes: part 28 – Debugging/Troubleshooting Kubernetes 29) Understanding Kubernetes: part 29 – Pod lifecycle 30) Understanding Kubernetes: part 30 – Deployment 31) Understanding Kubernetes: part 31 – ReplicaSet 32) Understanding Kubernetes: part 32 – DaemonSet 33) Understanding Kubernetes: part 33 – Container lifecycle events 34) Understanding Kubernetes: part 34 – Kubeconfig file 35) Understanding Kubernetes: part 35 – Labels & Selectors 36) Understanding Kubernetes: part 36 – Pod deletion

Posted on by:

aurelievache profile

Aurélie Vache

@aurelievache

Cloud Developer - Google Developer Expert on Cloud - Duchess France, Toulouse Data Science, DevFest Toulouse Leader/Organizer - speaker & sketchnoter newbie

Discussion

markdown guide
 

Can you tell us why cronjob is used instead of starting manually?

 

A cronjob can be useful for recurring "jobs".
If you want to run automatically a program which retrieve images and export them in PDF, for example, it's possible in a cronjob.
You can schedule the cronjob.

 

I mean, why run Kubernetes cronjobs? Why not just start it manually? Is it just to automate some task by invoking a pod?

It's for automated tasks yes.

A cronjob scheduled every 10 minutes, will spawn a new pod every 10 minutes.

If a pod failed, you can watch the logs, analyze and understand why this case has failed.

 

do you think you can use some font like Consolas or any fixed width font? Makes the command a little more clear:

 

I didn't find how to change the font in the software I use. I will take a look this evening 😉

 

👍👍👍 you can also use Google Docs... I wonder if it has Consolas now but I used it before so I still have it in my font list. You can use a Mac and use Monaco or Menlo. Windows has Lucida Sans Typewriter I believe.

I draw my sketchnotes in an Android tablet in an application and then export in jpg/PDF.

So I will check if I can change the font in the software.

 

Does not really show how to create a cron job.

 

Indeed, I can add how to create a cronjob 😉

 

Sketchnote improved 😉