{"id":482033,"date":"2022-08-07T11:04:13","date_gmt":"2022-08-07T08:04:13","guid":{"rendered":"https:\/\/en.buradabiliyorum.com\/how-to-clean-up-old-kubernetes-jobs\/"},"modified":"2022-08-07T11:04:13","modified_gmt":"2022-08-07T08:04:13","slug":"how-to-clean-up-old-kubernetes-jobs","status":"publish","type":"post","link":"https:\/\/buradabiliyorum.com\/en\/how-to-clean-up-old-kubernetes-jobs\/","title":{"rendered":"#How to Clean Up Old Kubernetes Jobs"},"content":{"rendered":"<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_84 counter-hierarchy ez-toc-counter ez-toc-custom ez-toc-container-direction\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<label for=\"ez-toc-cssicon-toggle-item-6a291c263393d\" class=\"ez-toc-cssicon-toggle-label\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #dd3333;color:#dd3333\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #dd3333;color:#dd3333\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/label><input type=\"checkbox\"  id=\"ez-toc-cssicon-toggle-item-6a291c263393d\" checked aria-label=\"Toggle\" \/><nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-1'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-clean-up-old-kubernetes-jobs\/#%E2%80%9CHow_to_Clean_Up_Old_Kubernetes_Jobs%E2%80%9D\" >&#8220;How to Clean Up Old Kubernetes Jobs&#8221;<\/a><ul class='ez-toc-list-level-2' ><li class='ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-clean-up-old-kubernetes-jobs\/#CronJob_History_Retention_Limits\" >CronJob History Retention Limits<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-clean-up-old-kubernetes-jobs\/#Finished_Job_TTLs\" >Finished Job TTLs<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-clean-up-old-kubernetes-jobs\/#Manually_Deleting_Jobs\" >Manually Deleting Jobs<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-clean-up-old-kubernetes-jobs\/#On-Demand_Batch_Deletions\" >On-Demand Batch Deletions<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-clean-up-old-kubernetes-jobs\/#Summary\" >Summary<\/a><\/li><\/ul><\/li><\/ul><\/nav><\/div>\n<h1><span class=\"ez-toc-section\" id=\"%E2%80%9CHow_to_Clean_Up_Old_Kubernetes_Jobs%E2%80%9D\"><\/span>&#8220;How to Clean Up Old Kubernetes Jobs&#8221;<span class=\"ez-toc-section-end\"><\/span><\/h1>\n<div>\n<img loading=\"lazy\" decoding=\"async\" class=\"type:primaryImage alignnone size-full wp-image-806255\" data-pagespeed-no-defer=\"\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/05\/Kubernetes-New.jpg?width=1198&amp;trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Graphic with the Kubernetes logo\" width=\"1202\" height=\"677\"\/><\/p>\n<p>Kubernetes <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/kubernetes.io\/docs\/concepts\/workloads\/controllers\/job\">Jobs<\/a> create Pods repeatedly until a specified number of containers terminate successfully. Jobs are often used with the higher-level <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/kubernetes.io\/docs\/concepts\/workloads\/controllers\/cron-jobs\">CronJob<\/a> mechanism that automatically starts new Jobs on a recurring schedule.<\/p>\n<p>Regular use of Jobs and CronJobs usually leads to a large number of objects lingering around in your cluster. Jobs and their Pods are <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/kubernetes.io\/docs\/concepts\/workloads\/controllers\/job\/#job-termination-and-cleanup\">intentionally kept indefinitely<\/a> after they complete. This is so you can inspect the Job\u2019s status and retrieve its logs in the future. However too many completed Jobs pollutes Kubectl output when you run commands like <code>kubectl get pods<\/code> or <code>kubectl get jobs<\/code>. This can make it harder to focus on relevant activity.<\/p>\n<p>In this article we\u2019ll share some methods for cleaning up old Jobs. You\u2019ll be able to remove redundant objects from your cluster, either automatically or on-demand.<\/p>\n<h2 id=\"cronjob-history-retention-limits\"><span class=\"ez-toc-section\" id=\"CronJob_History_Retention_Limits\"><\/span>CronJob History Retention Limits<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>Automatic clean-up has been supported for Jobs created by a CronJob since Kubernetes v1.6. This method lets you configure separate deletion thresholds for completed and failed Jobs.<\/p>\n<p>Enable the clean-up strategy by setting the <code>spec.successfulJobsHistoryLimit<\/code> and <code>spec.failedJobsHistoryLimit<\/code> fields on your CronJob object:<\/p>\n<div class=\"wp-geshi-highlight-wrap5\">\n<div class=\"wp-geshi-highlight-wrap4\">\n<div class=\"wp-geshi-highlight-wrap3\">\n<div class=\"wp-geshi-highlight-wrap2\">\n<div class=\"wp-geshi-highlight-wrap\">\n<div class=\"wp-geshi-highlight\">\n<div class=\"yaml\">\n<pre class=\"de1\"><span class=\"co3\">apiVersion<\/span><span class=\"sy2\">: <\/span>batch\/v1<span class=\"co3\">\nkind<\/span><span class=\"sy2\">: <\/span>CronJob<span class=\"co4\">\nmetadata<\/span>:<span class=\"co3\">\n  name<\/span><span class=\"sy2\">: <\/span>demo-cron<span class=\"co4\">\nspec<\/span>:<span class=\"co3\">\n  schedule<\/span><span class=\"sy2\">: <\/span><span class=\"st0\">\"* * * * *\"<\/span><span class=\"co3\">\n  successfulJobsHistoryLimit<\/span><span class=\"sy2\">: <\/span>5<span class=\"co3\">\n  failedJobsHistoryLimit<\/span><span class=\"sy2\">: <\/span>10<span class=\"co4\">\n  jobTemplate<\/span>:<span class=\"co4\">\n    spec<\/span>:<span class=\"co4\">\n      template<\/span>:<span class=\"co4\">\n        spec<\/span>:<span class=\"co4\">\n          containers<\/span>:<span class=\"co3\">\n            - name<\/span><span class=\"sy2\">: <\/span>demo-cron<span class=\"co3\">\n              image<\/span><span class=\"sy2\">: <\/span>busybox:latest<span class=\"co3\">\n              command<\/span><span class=\"sy2\">: <\/span><span class=\"br0\">[<\/span><span class=\"st0\">\"\/bin\/sh\"<\/span>, <span class=\"st0\">\"-c\"<\/span>, <span class=\"st0\">\"Job complete!\"<\/span><span class=\"br0\">]<\/span><\/pre>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<p>The CronJob shown above will retain the Job objects from its 10 most recent failed runs, as well as the five most recent successful ones.<\/p>\n<p>You\u2019ll have a maximum of 15 old Jobs in your cluster at any given time. Those 15 will be retained indefinitely. They\u2019ll only be deleted when they\u2019re superseded by a newer Job that finishes with the same status.<\/p>\n<p>Default CronJob history limits are <a href=\"https:\/\/buradabiliyorum.com\/en\/category\/download-scripts-themes-apps\/\" data-internallinksmanager029f6b8e52c=\"9\" title=\"Download Scripts &amp; Themes &amp; Apps\" target=\"_blank\" rel=\"noopener\">app<\/a>lied when you omit custom values in your manifest. Kubernetes usually retains three successful jobs and one failed one. The value <code>0<\/code> is supported to delete Jobs im<a href=\"https:\/\/buradabiliyorum.com\/en\/category\/social-mediaa\/\" data-internallinksmanager029f6b8e52c=\"1\" title=\"Social Media\" target=\"_blank\" rel=\"noopener\">media<\/a>tely after they finish, without retaining any.<\/p>\n<h2 id=\"finished-job-ttls\"><span class=\"ez-toc-section\" id=\"Finished_Job_TTLs\"><\/span>Finished Job TTLs<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p><a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/kubernetes.io\/docs\/concepts\/workloads\/controllers\/ttlafterfinished\">Job TTLs<\/a> are a newer Kubernetes addition that became stable in v1.23. TTLs are set directly on your Job objects so you don\u2019t need to be using CronJobs. The TTL directs Kubernetes to delete the Job and its Pods after a fixed time has elapsed, irrespective of the Job\u2019s completion status.<\/p>\n<p>You can enable this mechanism by setting the <code>spec.ttlSecondsAfterFinished<\/code> field on your Job objects:<\/p>\n<div class=\"wp-geshi-highlight-wrap5\">\n<div class=\"wp-geshi-highlight-wrap4\">\n<div class=\"wp-geshi-highlight-wrap3\">\n<div class=\"wp-geshi-highlight-wrap2\">\n<div class=\"wp-geshi-highlight-wrap\">\n<div class=\"wp-geshi-highlight\">\n<div class=\"yaml\">\n<pre class=\"de1\"><span class=\"co3\">apiVersion<\/span><span class=\"sy2\">: <\/span>batch\/v1<span class=\"co3\">\nkind<\/span><span class=\"sy2\">: <\/span>Job<span class=\"co4\">\nmetadata<\/span>:<span class=\"co3\">\n  name<\/span><span class=\"sy2\">: <\/span>demo-job<span class=\"co4\">\nspec<\/span>:<span class=\"co3\">\n  ttlSecondsAfterFinished<\/span><span class=\"sy2\">: <\/span>300<span class=\"co4\">\n  template<\/span>:<span class=\"co4\">\n    spec<\/span>:<span class=\"co4\">\n      containers<\/span>:<span class=\"co3\">\n        - name<\/span><span class=\"sy2\">: <\/span>demo-cron<span class=\"co3\">\n          image<\/span><span class=\"sy2\">: <\/span>busybox:latest<span class=\"co3\">\n          command<\/span><span class=\"sy2\">: <\/span><span class=\"br0\">[<\/span><span class=\"st0\">\"\/bin\/sh\"<\/span>, <span class=\"st0\">\"-c\"<\/span>, <span class=\"st0\">\"Job complete!\"<\/span><span class=\"br0\">]<\/span><\/pre>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<p>If your Job\u2019s defined as part of a CronJob, make sure you nest the field inside the <code>jobTemplate<\/code>:<\/p>\n<div class=\"wp-geshi-highlight-wrap5\">\n<div class=\"wp-geshi-highlight-wrap4\">\n<div class=\"wp-geshi-highlight-wrap3\">\n<div class=\"wp-geshi-highlight-wrap2\">\n<div class=\"wp-geshi-highlight-wrap\">\n<div class=\"wp-geshi-highlight\">\n<div class=\"yaml\">\n<pre class=\"de1\"><span class=\"co3\">apiVersion<\/span><span class=\"sy2\">: <\/span>batch\/v1<span class=\"co3\">\nkind<\/span><span class=\"sy2\">: <\/span>CronJob<span class=\"co4\">\nmetadata<\/span>:<span class=\"co3\">\n  name<\/span><span class=\"sy2\">: <\/span>demo-cron<span class=\"co4\">\nspec<\/span>:<span class=\"co3\">\n  schedule<\/span><span class=\"sy2\">: <\/span><span class=\"st0\">\"* * * * *\"<\/span><span class=\"co4\">\n  jobTemplate<\/span>:<span class=\"co4\">\n    spec<\/span>:<span class=\"co3\">\n      ttlSecondsAfterFinished<\/span><span class=\"sy2\">: <\/span>300<span class=\"co4\">\n      template<\/span>:<span class=\"co4\">\n        spec<\/span>:<span class=\"co4\">\n          containers<\/span>:<span class=\"co3\">\n            - name<\/span><span class=\"sy2\">: <\/span>demo-cron<span class=\"co3\">\n              image<\/span><span class=\"sy2\">: <\/span>busybox:latest<span class=\"co3\">\n              command<\/span><span class=\"sy2\">: <\/span><span class=\"br0\">[<\/span><span class=\"st0\">\"\/bin\/sh\"<\/span>, <span class=\"st0\">\"-c\"<\/span>, <span class=\"st0\">\"Job complete!\"<\/span><span class=\"br0\">]<\/span><\/pre>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<p>The examples above will mark Jobs as eligible for deletion five minutes (300 seconds) after they finish. This occurs regardless of whether the Job ends up in the Complete or Failed state.<\/p>\n<p>Deletions based on this mechanism are managed by a dedicated controller inside your cluster. The controller monitors Job objects, detects when a TTL has expired, and then takes action to clean up the affected Job and its dependent resources. There could be a short delay between the TTL expiring and the controller stepping in to enact the deletion.<\/p>\n<p>Setting a Job\u2019s TTL to <code>0<\/code> will make it eligible for deletion as soon as it finishes. You should consider whether this is appropriate for each of your tasks. Not retaining any history can make it harder to debug problems as you won\u2019t be able to retrieve container logs.<\/p>\n<p>The <code>ttlSecondsAfterFinished<\/code> field is mutable. You can change it on existing Jobs at any time. Modifications aren\u2019t guaranteed to affect executions that have already been created though. Extending a Job\u2019s TTL could still delete runs that were scheduled while the previous value applied.<\/p>\n<h2 id=\"manually-deleting-jobs\"><span class=\"ez-toc-section\" id=\"Manually_Deleting_Jobs\"><\/span>Manually Deleting Jobs<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>You can always manually delete a Job using Kubectl. First retrieve your list of Jobs:<\/p>\n<pre>$ kubectl get jobs&#13;\nNAME                 COMPLETIONS   DURATION   AGE&#13;\ndemo-cron-27549499   1\/1           2s         36s<\/pre>\n<p>Next issue the <code>delete job<\/code> command with the name of your selected job:<\/p>\n<pre>$ kubectl delete job demo-cron-27549499&#13;\njob.batch \"demo-cron-27549499\" deleted<\/pre>\n<p>This will delete the Job and clean up the Pods and other objects associated with it.<\/p>\n<h3 id=\"on-demand-batch-deletions\"><span class=\"ez-toc-section\" id=\"On-Demand_Batch_Deletions\"><\/span>On-Demand Batch Deletions<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>You can rapidly clean up multiple Jobs by filtering with field selectors. Here\u2019s an example which will delete all successful jobs in your active namespace:<\/p>\n<pre>$ kubectl delete jobs --field-selector status.successful=1&#13;\njob.batch \"demo-cron-27549501\" deleted&#13;\njob.batch \"demo-cron-27549502\" deleted&#13;\njob.batch \"demo-cron-27549503\" deleted<\/pre>\n<p>This is much less laborious than deleting individual Jobs in sequence.<\/p>\n<p>To delete all the Jobs associated with a specific CronJob, it\u2019s best to set a label on those Jobs that identifies the parent CronJob. Define the label using your CronJob\u2019s <code>spec.jobTemplate.metadata.labels<\/code> field:<\/p>\n<div class=\"wp-geshi-highlight-wrap5\">\n<div class=\"wp-geshi-highlight-wrap4\">\n<div class=\"wp-geshi-highlight-wrap3\">\n<div class=\"wp-geshi-highlight-wrap2\">\n<div class=\"wp-geshi-highlight-wrap\">\n<div class=\"wp-geshi-highlight\">\n<div class=\"yaml\">\n<pre class=\"de1\"><span class=\"co3\">apiVersion<\/span><span class=\"sy2\">: <\/span>batch\/v1<span class=\"co3\">\nkind<\/span><span class=\"sy2\">: <\/span>CronJob<span class=\"co4\">\nmetadata<\/span>:<span class=\"co3\">\n  name<\/span><span class=\"sy2\">: <\/span>demo-cron<span class=\"co4\">\nspec<\/span>:<span class=\"co3\">\n  schedule<\/span><span class=\"sy2\">: <\/span><span class=\"st0\">\"* * * * *\"<\/span><span class=\"co4\">\n  jobTemplate<\/span>:<span class=\"co4\">\n    metadata<\/span>:<span class=\"co4\">\n      labels<\/span>:<span class=\"co3\">\n        cron-job<\/span><span class=\"sy2\">: <\/span>demo-cron<span class=\"co4\">\n    spec<\/span>:<span class=\"co4\">\n      template<\/span>:<span class=\"co4\">\n        spec<\/span>:<span class=\"co4\">\n          containers<\/span>:<span class=\"co3\">\n            - name<\/span><span class=\"sy2\">: <\/span>demo-cron<span class=\"co3\">\n              image<\/span><span class=\"sy2\">: <\/span>busybox:latest<span class=\"co3\">\n              command<\/span><span class=\"sy2\">: <\/span><span class=\"br0\">[<\/span><span class=\"st0\">\"\/bin\/sh\"<\/span>, <span class=\"st0\">\"-c\"<\/span>, <span class=\"st0\">\"Job complete!\"<\/span><span class=\"br0\">]<\/span><\/pre>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<p>You can delete Jobs created by this version of the <code>demo-cron<\/code> CronJob using the following command:<\/p>\n<pre>$ kubectl delete jobs -l cron-job=demo-cron&#13;\njob.batch \"demo-cron-27549501\" deleted&#13;\njob.batch \"demo-cron-27549502\" deleted&#13;\njob.batch \"demo-cron-27549503\" deleted<\/pre>\n<p>Combining this example with a field selector lets you delete <code>demo-cron<\/code> runs that are in a particular state:<\/p>\n<pre>$ kubectl delete jobs -l cron-job=demo-cron --field-selector status.successful=0&#13;\njob.batch \"demo-cron-27549501\" deleted&#13;\njob.batch \"demo-cron-27549502\" deleted&#13;\njob.batch \"demo-cron-27549503\" deleted<\/pre>\n<p>This command deletes failed Jobs that were scheduled by the <code>demo-cron<\/code> CronJob.<\/p>\n<h2 id=\"summary\"><span class=\"ez-toc-section\" id=\"Summary\"><\/span>Summary<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>Kubernetes Jobs usually stick around in your cluster after they finish. This behavior lets you retrieve their logs at arbitrary future times but quickly leads to excessive object accumulation.<\/p>\n<p>CronJobs come with retention limits that are on by default and support separate configuration for successful and failed runs. This should be your preferred mechanism for managing scheduled Jobs. Other kinds of Job are best configured with a TTL that will automatically clean up resources after a fixed time period.<\/p>\n<p>Although Kubernetes has historically kept old Jobs indefinitely, it\u2019s <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/kubernetes.io\/docs\/concepts\/workloads\/controllers\/job\/#ttl-mechanism-for-finished-jobs\">now recommended that<\/a> you use the TTL mechanism wherever possible. Having too many old Jobs in your cluster can cause performance degradation as the control plane has to monitor the objects and the Pods they\u2019ve created.<\/p>\n<\/div>\n<p><script>\n setTimeout(function(){\n  !function(f,b,e,v,n,t,s)\n  {if(f.fbq)return;n=f.fbq=function(){n.callMethod?\n  n.callMethod.apply(n,arguments):n.queue.push(arguments)};\n  if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';\n  n.queue=[];t=b.createElement(e);t.async=!0;\n  t.src=v;s=b.getElementsByTagName(e)[0];\n  s.parentNode.insertBefore(t,s) } (window, document,'script',\n  'https:\/\/connect.facebook.net\/en_US\/fbevents.js');\n   fbq('init', '335401813750447');\n   fbq('track', 'PageView');\n  },3000);\n<\/script><\/p>\n<blockquote><p><strong><span style=\"color: #ff6600;\">If you liked the article, do not forget to share it with your friends. Follow us on\u00a0<span style=\"color: #ff0000;\"><a style=\"color: #ff0000;\" href=\"https:\/\/news.google.com\/publications\/CAAqBwgKMLG0nwswvr63Aw\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">Google News<\/a><\/span>\u00a0too, click on the star and choose us from your favorites.<\/span><\/strong><\/p><\/blockquote>\n<blockquote>\n<p style=\"text-align: center;\">For forums sites go to <span style=\"color: #ff9900;\"><a style=\"color: #ff9900;\" href=\"https:\/\/forum.buradabiliyorum.com\/\" target=\"_blank\" rel=\"noopener\">Forum.BuradaBiliyorum.Com<\/a><\/span><\/strong><\/p>\n<\/blockquote>\n<blockquote>\n<p style=\"text-align: center;\"><strong>If you want to read more like this article, you can visit our <span style=\"color: #ff9900;\"><a style=\"color: #ff9900;\" href=\"https:\/\/en.buradabiliyorum.com\/technology\/\" target=\"_blank\" rel=\"noopener\">Technology category.<\/a><\/span><\/strong><\/p>\n<\/blockquote>\n<p><span style=\"color: black;\"><a style=\"color: #ff9900;\" href=\"https:\/\/www.howtogeek.com\/devops\/how-to-clean-up-old-kubernetes-jobs\/\" target=\"_blank\" rel=\"noopener\">Source<\/a><\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>&#8220;How to Clean Up Old Kubernetes Jobs&#8221; Kubernetes Jobs create Pods repeatedly until a specified number of containers terminate successfully. Jobs are often used with the higher-level CronJob mechanism that automatically starts new Jobs on a recurring schedule. Regular use of Jobs and CronJobs usually leads to a large number of objects lingering around in&#8230;<\/p>\n","protected":false},"author":1,"featured_media":482034,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"fifu_image_url":"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2022\/05\/Kubernetes-New.jpg?height=200p&trim=2,2,2,2","fifu_image_alt":"","footnotes":""},"categories":[18],"tags":[],"class_list":["post-482033","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-technology"],"_links":{"self":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts\/482033","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/comments?post=482033"}],"version-history":[{"count":0,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts\/482033\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/media\/482034"}],"wp:attachment":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/media?parent=482033"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/categories?post=482033"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/tags?post=482033"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}