Manage podman with systemd
After getting the containers running you can have systemd start and stop them for you.
$ podman pull docker.io/library/httpd $ podman run -dt -p 8080:80/tcp --name httpd docker.io/library/httpd
Now you can create systemd files:
$ cd $HOME/.config/systemd/user $ podman generate systemd --new --files --name httpd
The podman generate command creates a systemd service file named container-httpd.service. Reload the daemon to read the new file:
$ systemctl --user daemon-reload
Stop the running container
- Read more about Manage podman with systemd
- Log in or register to post comments