-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Add podman-restart systemd unit file #10595
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code LGTM.
Any chance we could test the podman-restart.service
in CI?
A simple test with podman create --restart=always --name foo
, followed by a systemctl start podman-restart.service
and then making sure foo
is running should work (tested locally).
@lsm5 @jnovy PTAL for the packaging parts. Is there a way to enable the service by default in rpm?
Not trivially, but it's doable. One will need to hand-copy the service file into the systemd directory, |
Now going to work on the tests for the unit file. |
I am fine with getting this in without tests, for now. We can open a separate PR for tests. Would like to get this out to the world to test, since it has been requested for some time. |
Should this not require network or whatnot though? Or what makes this be scheduled late enough that started things won't immediately break? |
Good point, it should probably be [Install] We should add this to podman.service and add [Install] to podman.socket |
LGTM |
* Add podman-restart systemd unit file and add it to podman RPM package * Fix podman start to filter all containers + unit test Signed-off-by: Boaz Shuster <[email protected]>
LGTM |
/lgtm |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: boaz0, rhatdan The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Pardon if this is an ignorant comment, but doesn't adding
to |
As long as no other service "Requires" |
@Aposhian Podman does not require a long running daemon to run. If apps like docker compose or docker-py or podman-py want to talk to a restapi to launch a service. We added options to podman system service to be able to service this API. Podman will act as a socket activated service to launch containers for the API. You can run multiple of these services if you wanted to, and it runs rootless and rootfull. The service goes down within 5 seconds of the last connection. If you want to call this a daemon, then fine. |
closes #10539
closes #9579