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

looking forward to auto-restart capability when node reboot #48

Closed
panpan0000 opened this issue Jan 16, 2023 · 6 comments
Closed

looking forward to auto-restart capability when node reboot #48

panpan0000 opened this issue Jan 16, 2023 · 6 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@panpan0000
Copy link

panpan0000 commented Jan 16, 2023

background: kubernetes-sigs/kind#2998

the podman-restart.service should be included on Podman 4.4.0 and onwards
https://github.com/containers/podman/pull/16672
https://github.com/containers/podman/issues/16669

So I guess two works need to be done:
(1) upgrade podman from 4.2.1 to 4.4.0
(2) include the podman-restart service in static release

@panpan0000
Copy link
Author

panpan0000 commented Jan 16, 2023

I just download podman-4.3.1-1.1.x86_64.rpm or podman-4.2.1-150500.1.2.x86_64.rpm

, there's already /usr/lib/systemd/system/podman-restart.service in the package.

So it seems 4.2.1 already include podman-restart, but I didn't find it in our static repo. maybe just add this service will help ?

@mgoltzsche
Copy link
Owner

@panpan0000 so as I understand you want the podman-restart systemd service to be redistributed by this repository.

Currently this does not make sense to me because the container image and binaries shipped by this repository explicitly don't support systemd and are built primarily to run on systems without systemd.
Also, it looks like restarting a podman container is the caller's responsibility, not the responsibility of podman itself. (This makes sense since podman is not designed as a daemon like containerd/dockerd.)
If you want to make podman containers restart on boot, you have to run those additonal commands somehow on boot or, if you're using systemd as init system, simply download the podman-restart.service template.

Regarding the update: podman 4.4.0 is not stable yet but the latest stable podman update 4.3.1 should also be shipped by this repo indeed.

@mgoltzsche
Copy link
Owner

mgoltzsche commented Jan 19, 2023

I am closing this issue now. In case you have strong argument for redistributing the systemd unit with the tar within this repo, please feel free to reopen the issue.

@panpan0000
Copy link
Author

got you @mgoltzsche . Thank you for your response !

@mgoltzsche
Copy link
Owner

mgoltzsche commented Mar 24, 2023

I see now it would be convenient for users to have the systemd unit shipped with the tar archive. After all it does not increase the archive's size significantly and users could still decide whether or not they want to enable it.
(Also, I noticed podman supports the podman generate systemd command now.)
Feel free to create a pull request. Otherwise I might be able to add it to the next release myself.

@mgoltzsche mgoltzsche reopened this Mar 24, 2023
@mgoltzsche mgoltzsche added enhancement New feature or request good first issue Good for newcomers labels Mar 24, 2023
@mgoltzsche
Copy link
Owner

mgoltzsche commented Apr 8, 2023

Release v4.4.4 provides /usr/lib/systemd/system/podman-restart.service with the tar archive (f82c88f and c909610).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants