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

[email protected]: do not exit as error when preventing restart #2141

Open
wants to merge 1 commit into
base: core/jammy
Choose a base branch
from

Conversation

valentindavid
Copy link
Contributor

Upstreaming of canonical/core-base#296

This does not affect behavior apart from systemctl not showing the service in red.

@dbungert
Copy link
Collaborator

Thanks Valentin.

I have a question - I'm looking at this combination and it seems a little unexpected

RestartPreventExitStatus=22
SuccessExitStatus=22
Restart=always

We're deliberately using exit 22 as success (fine) and not restarting with that (fine), but that means that an exit 0 would be a restart while exit 22 would not restart, is this intended?

I wonder if we instead want this, which means an exit 0 doesn't restart and we don't need RestartPreventExitStatus. Thoughts?

SuccessExitStatus=22
Restart=on-failure

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

Successfully merging this pull request may close these issues.

2 participants