-
Notifications
You must be signed in to change notification settings - Fork 14
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
Disable cron for "Stopped" services #9
Comments
Good idea, thats easy enough, just add a check here and "continue" if I'm pretty busy at the moment, I plan to certainly address it in the future, otherwise PRs are welcome! |
I took a quick look at this. At first glance I'd say the major hangup is that the rancher-metadata service does not expose the state of the service. It only does so for containers and that's not helpful because the containers themselves are naturally going to be stopped most of the time. |
Yeah, metadata might not be the best option for this - its great to quickly get a container with a specific label, but not much else (for this use case). Rancher API does have ability to get |
Any chance of rolling out a new release so that these changes are available in the official image? |
While debugging (or calming backend services) I sometimes need to temporarily disable a cron-ed service.
I tried setting the service to "Stopped" but rancher-cron runs the service anyway. My current workaround is to "upgrade" services and change the rancher-cron label to something like 'off....' to preserve the crontab entry format but disable.
It would be ideal if rancher-cron could poll the api and not start cron services if they are "Stopped"
The text was updated successfully, but these errors were encountered: