Fix auto-pause interval value not immediately being taking affect #17945
Labels
area/addons
co/auto-pause
lifecycle/frozen
Indicates that an issue or PR should not be auto-closed due to staleness.
priority/backlog
Higher priority than priority/awaiting-more-evidence.
In #17936 I implemented making the auto-pause interval configurable, from the PR:
As stated, when the user executes
minikube addons configure auto-pause
the change doesn't immediately take effect andsystemctl daemon-reload
&systemctl restart auto-pause.service
need to be run. Callingsysinit.New(co.CP.Runner).Restart("auto-pause")
would fix it, but the messy part is gettingco
which you would normally get viaco := mustload.Running(profile)
. If we do implement it that way thenminikube addons configure auto-pause
with return an error when trying to execute the command when the cluster is stopped. But it gets confusing as the new interval value would actually be updated in the config, it's just themustload.Running(profile)
that failing.We should only call
mustload.Running(profile)
after we confirm that the cluster is running, otherwise just update the value in the config.The text was updated successfully, but these errors were encountered: