What Is Podman?
Podman is a daemonless container engine that is compatible with Docker CLI commands. Its key advantage is running containers without root privileges, improving security.
Install Podman
# Ubuntu 22.04+
sudo apt install -y podman
# Rocky/Alma Linux
sudo dnf install -y podmanBasic Usage (Same as Docker)
podman run -d --name web -p 8080:80 nginx
podman ps
podman logs web
podman stop web
podman rm webRootless Containers
Podman runs containers as your regular user by default — no daemon, no root required:
# As regular user (no sudo)
podman run -d -p 8080:80 nginx
podman images
podman psPodman Compose
pip3 install podman-compose
# Use existing docker-compose.yml files
podman-compose up -d
podman-compose downGenerating Systemd Services
Podman can generate systemd unit files for container management:
# Generate a service file
podman generate systemd --new --name web > ~/.config/systemd/user/container-web.service
# Enable and start
systemctl --user daemon-reload
systemctl --user enable --now container-web.service
# Auto-start on boot (even without login)
loginctl enable-linger $USERKey Differences from Docker
| Feature | Docker | Podman |
|---|---|---|
| Daemon | Required (dockerd) | Daemonless |
| Root required | Default yes | Default no |
| Compose | docker compose | podman-compose |
| Pods | Swarm/K8s | Native pod support |
| Systemd | Limited | First-class |
Docker Compatibility
# Alias for seamless transition
alias docker=podmanMost Docker commands work identically with Podman. The main exceptions are Docker Swarm features and certain network plugins.