Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Schedule one-time job execution after a certain time #162

Open
stefanneuhaus opened this issue Jul 15, 2024 · 2 comments
Open

Schedule one-time job execution after a certain time #162

stefanneuhaus opened this issue Jul 15, 2024 · 2 comments

Comments

@stefanneuhaus
Copy link

I am facing difficulties when using at to schedule a one-time job after a certain time like this:


at -f ./my-script.sh now + 1 minute

Using atq I can verify that the job is actually scheduled. But the job won't start before scheduling another job execution using at. I am wondering if running this inside a container might be the cause. What are your thoughts on this?

If this is actually caused by the execution inside the container, than having supercronic support this case might be valuable.

@UserNotFound
Copy link
Member

I don't think I understand your issue, can you share how this is related to Supercronic? An example crontab would be great.

@stefanneuhaus
Copy link
Author

Sure. Actually my issue is twofold:

a) I am currently facing the following problem: I need to start a job inside my container with a certain time offset (+1 min) after container start. Normally I would use at for this. Unfortunately I am facing issues when using "at" inside a container (works perfectly outside a container). My first thought was that this might by caused by the same things that hinder use of cron jobs inside a container and that led to the development of supercronic. Hence I was wondering what your thoughts on this are.

b) One solution to the problem would be to extend supercronic to support one-time asynchronous tasks. As this is not super clean I would fully understand if you had any objections.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants