{"id":18299662,"url":"https://github.com/containersolutions/delayed-jobs-operator","last_synced_at":"2025-04-05T13:35:11.679Z","repository":{"id":87117948,"uuid":"429812176","full_name":"ContainerSolutions/delayed-jobs-operator","owner":"ContainerSolutions","description":null,"archived":false,"fork":false,"pushed_at":"2021-11-23T11:29:11.000Z","size":210,"stargazers_count":9,"open_issues_count":1,"forks_count":1,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-03-21T05:11:31.626Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ContainerSolutions.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-11-19T13:43:59.000Z","updated_at":"2024-08-13T03:36:57.000Z","dependencies_parsed_at":"2023-06-19T18:07:34.810Z","dependency_job_id":null,"html_url":"https://github.com/ContainerSolutions/delayed-jobs-operator","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ContainerSolutions%2Fdelayed-jobs-operator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ContainerSolutions%2Fdelayed-jobs-operator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ContainerSolutions%2Fdelayed-jobs-operator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ContainerSolutions%2Fdelayed-jobs-operator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ContainerSolutions","download_url":"https://codeload.github.com/ContainerSolutions/delayed-jobs-operator/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247342634,"owners_count":20923631,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-05T15:09:49.558Z","updated_at":"2025-04-05T13:35:11.373Z","avatar_url":"https://github.com/ContainerSolutions.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Delayed Job Operator\n\nDelaying the start of Jobs until after a Unix Timestamp.\n\nThis might be useful if you need to do something at a specific time, once and then cleaned up.\n\nWhy not use a CronJob with a specific day / time set ?\n\n\u003e CronJobs would achieve the goal of running at a specific time,  \n\u003e but still exist in the Kubernetes API.  \n\u003e If you list CronJobs, you could have a high noise vs. signal.  \n\u003e If you are running it only once, a CronJob might be a better idea.  \n\u003e This Operator exists for cases where many delayed jobs need to be created often or regularly.\n\nWhy not us a Job with a `sleep` statement.\n\n\u003e This would create a pod running for the specified amount of time, and then run the job,\n\u003e which would solve the problem, but any pod rescheduling or restarts will reset the timer,\n\u003e and no guarantees can be made about the specific time when a job will be run.\n\nEssentially a Job is missing the scheduling capability, and a CronJob is missing the TTL capability.\n\nWhat this Operator tries to achieve is to add a scheduling component to a normal Job.\n\nIt will simply delay the execution of a Job until a specified time, \nalso allowing extending that time by editing the `.spec.delayUntil` field.\n\n## Usage\n\nThe CRD for a delayed job is the same as a normal job, except for `apiVersion`, `kind`, and `.spec.delayUntil`\n\n```yaml\n# New Version and kind\napiVersion: batch.container-solutions.com/v1alpha1\nkind: DelayedJob\nmetadata:\n  name: delayedjob-sample\nspec:\n  \n  # New field to delay the job until a specific time\n  delayUntil: 1637351107\n  \n  # The rest is identical to a normal Job, and in fact uses the same underlying constructs\n  template:\n    spec:\n      containers:\n        - name: pi\n          image: perl\n          command: [\"perl\",  \"-Mbignum=bpi\", \"-wle\", \"print bpi(2000)\"]\n      restartPolicy: Never\n  backoffLimit: 4\n```\n\n## Installing the Operator\n\nWe have created a simplified bundle to install the Operator, which can easily be installed sing `kustomize`\n\n```bash\nkustomize build https://github.com/ContainerSolutions/delayed-jobs-operator.git/config/simple | kubectl apply -f -\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcontainersolutions%2Fdelayed-jobs-operator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcontainersolutions%2Fdelayed-jobs-operator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcontainersolutions%2Fdelayed-jobs-operator/lists"}