How To Install Podman on Ubuntu 22.04 LTS
In this tutorial, we will show you how to install Podman on Ubuntu 22.04 LTS. For those of you who didn’t know, Podman is a container tool for virtualizing applications. It was originally developed by Red Hat and originated in the Cri-O project, which develops a lightweight container runtime environment alternative to the Docker runtime environment. Podman distinguishes itself from its competitors by allowing you to run Containers in both root and rootless modes. Additionally, Podman isn’t a running service, meaning that it’s daemons.
This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘
sudo‘ to the commands to get root privileges. I will show you the step-by-step installation of the Podman on Ubuntu 22.04 (Jammy Jellyfish). You can follow the same instructions for Ubuntu 22.04 and any other Debian-based distribution like Linux Mint, Elementary OS, Pop!_OS, and more as well.
- A server running one of the following operating systems: Ubuntu 22.04, 20.04, and any other Debian-based distribution like Linux Mint.
- It’s recommended that you use a fresh OS install to prevent any potential issues.
- SSH access to the server (or just open Terminal if you’re on a desktop).
non-root sudo useror access to the
root user. We recommend acting as a
non-root sudo user, however, as you can harm your system if you’re not careful when acting as the root.
Install Podman on Ubuntu 22.04 LTS Jammy Jellyfish
Step 1. First, make sure that all your system packages are up-to-date by running the following
apt commands in the terminal.
sudo apt update sudo apt upgrade
Step 2. Installing Podman on Ubuntu 22.04.
By default, the Podman is available on Ubuntu 22.04 base repository. Now run the following command below to install the latest version of Podman to your Ubuntu system:
sudo apt install podman
Now check the version of the installed Podman using the following command:
You can also see detailed information about Podman with the following command:
Step 3. Configure Podman Registry.
By default, the Podman registry is not configured to download and install container images from the web, hence we need to do that manually so that we can use popular repositories such as Docker.io, and Fedora:
Add the following lines:
[registries.search] registries=["registry.access.redhat.com", "registry.fedoraproject.org", "docker.io"]
Step 3. How to use Podman.
Just like Docker, we can use the Podman command line to search Images but from different repositories, added in the previous step. You can search for the Podman images in the registries you have specified as:
podman search debian
Next, download the latest Debian image from the internet using the following command:
podman pull debian
If you have downloaded multiple images and now want to see what are the available images on your system, we can list all of them using the given command:
Additionally, you can view the running containers by using this command:
sudo podman ps -a
You can list all Podman command options with the following command:
Manage pods, containers and images Usage: podman [options] [command] Available Commands: attach Attach to a running container auto-update Auto update containers according to their auto-update policy build Build an image using instructions from Containerfiles commit Create new image based on the changed container container Manage containers cp Copy files/folders between a container and the local filesystem create Create but do not start a container diff Display the changes to the object's file system events Show podman events exec Run a process in a running container export Export container's filesystem contents as a tar archive generate Generate structured data based on containers, pods or volumes healthcheck Manage health checks on containers help Help about any command history Show history of a specified image image Manage images images List images in local storage import Import a tarball to create a filesystem image info Display podman system information init Initialize one or more containers inspect Display the configuration of object denoted by ID kill Kill one or more running containers with a specific signal load Load image(s) from a tar archive login Login to a container registry logout Logout of a container registry logs Fetch the logs of one or more containers machine Manage a virtual machine manifest Manipulate manifest lists and image indexes mount Mount a working container's root filesystem network Manage networks pause Pause all the processes in one or more containers play Play containers, pods or volumes from a structured file pod Manage pods port List port mappings or a specific mapping for the container ps List containers pull Pull an image from a registry push Push an image to a specified destination rename Rename an existing container restart Restart one or more containers rm Remove one or more containers rmi Removes one or more images from local storage run Run a command in a new container save Save image(s) to an archive search Search registry for image secret Manage secrets start Start one or more containers stats Display a live stream of container resource usage statistics stop Stop one or more containers system Manage podman tag Add an additional name to a local image top Display the running processes of a container unmount Unmounts working container's root filesystem unpause Unpause the processes in one or more containers unshare Run a command in a modified user namespace untag Remove a name from a local image version Display the Podman version information volume Manage volumes wait Block on one or more containers
Congratulations! You have successfully installed Podman. Thanks for using this tutorial for installing Podman on Ubuntu 22.04 LTS Jammy Jellyfish system. For additional help or useful information, we recommend you check the Podman website.