How to Install Podman on Ubuntu Linux

This article describes steps one can take to install Podman on Ubuntu Linux.

Podman (aka, Pod Manager) is an open-source tool that makes it easy to find, run, build, share, and deploy applications using containers and container images.

If you already use Docker Container Engine and are familiar with the command line, Podman should be easy to get used to. It is part of the lib pod library that doesn’t rely on the Docker daemon and is compatible with Docker.

If you are completely new to containers, check out the Introduction. For power users or those coming from Docker, check out our Tutorials.

Below is how to install Podman on Ubuntu Linux.

How to install Podman on Ubuntu Linux

As described above, Podman makes it easy to find, run, build, share, and deploy applications using containers and container images.

Below is how to install and configure it in Ubuntu Linux.

Install Podman from Ubuntu’s Repositories

The Podman packages are included in Ubuntu’s default system repositories by default.

One can run the commands below to install Podman.

sudo apt update
sudo apt install podman

Installing packages from Ubuntu’s repositories may not necessarily be the latest version available since Ubuntu only includes stable, typically older ones.

Once installed, you can run the commands below to view the version installed.

podman -v

The command above should provide the version number for Podman.

For more detailed information, run the Podman command.

podman info

How to configure Podman in Ubuntu Linux

After Podman is installed, you will want to allow it to download container images from the web. It is disabled by default. This can be done via Podman’s registries.conf file.

Run the commands below to open Podman’s registries.conf file.

sudo nano /etc/containers/registries.conf

Then add the following lines in the file and save.

[registries.search]
registries=["registry.access.redhat.com", "registry.fedoraproject.org", "docker.io"]

Once the file is updated, you should now be able to download container images.

How to download and manage container images via Podman

As with most container orchestrators, Podman works the same way. To search for images online, run the commands below.

podman search debian

That should provide you with a list of available images you can download.

INDEX       NAME                                           DESCRIPTION                                      STARS       OFFICIAL
docker.io   docker.io/library/ubuntu                       Ubuntu is a Debian-based Linux operating sys...  15005       [OK]        
docker.io   docker.io/library/debian                       Debian is a Linux distribution that's compos...  4444        [OK]        
docker.io   docker.io/library/neurodebian                  NeuroDebian provides neuroscience research s...  93          [OK]        
docker.io   docker.io/bitnami/debian-base-buildpack        Debian base compilation image                    2           [OK]
docker.io   docker.io/mirantis/debian-build-ubuntu-xenial                                                   0                       
docker.io   docker.io/mirantis/debian-build-ubuntu-trusty                                                   0

You can then use the pull with the Podman command to download images of the OS you mentioned.

podman pull debian

You can manage your containers via Podman, which is similar to Docker and others.

Once you have downloaded the image, you can create and manage your container using the downloaded image file.

Create a container for Debian:

podman run -dit --name debian-container debian

Connect to your container:

podman attach debian-container

Start, Stop, and Delete your container and image:

podman start debian-container
podman stop debian-container
podman rm debian-container
podman rmi debian

Again, Podman can be a great alternative to Docker and other container managers. Visit the help page above for more information.

That should do it!

Conclusion:

  • Installation: This article detailed the step-by-step process to install Podman from Ubuntu’s repositories, ensuring ease and efficiency.
  • Configuration: A guide on configuring Podman in Ubuntu Linux, enabling users to download container images from the web by altering the registries.conf file.
  • Management: Instructions on downloading and managing container images via Podman, along with commands to create, connect, start, stop, and delete containers and images.
  • Versatility: Highlighted Podman as a powerful alternative to Docker and other container managers, suggesting its suitability for various user levels and needs.
  • Feedback: Encouraged readers to engage through the comment section for any adjustments or additional insights.

Frequently Asked Questions

What is Podman and how does it differ from Docker?

Podman, or Pod Manager, is an open-source tool for managing containers and container images. Unlike Docker, Podman does not rely on a daemon and is compatible with Docker commands, making it easier for Docker users to transition.

How do I install Podman on Ubuntu Linux?

To install Podman on Ubuntu, you can use the default system repositories. Simply run the commands 'sudo apt update' followed by 'sudo apt install podman' in your terminal.

How can I check the installed version of Podman?

After installing Podman, you can check the version by running the command 'podman -v' in your terminal. This will display the version number of Podman that is currently installed.

”How

”By
' section.”]

What command do I use to search for container images in Podman?

To search for container images using Podman, you can use the command 'podman search '. For example, 'podman search debian' will list available Debian images that you can download.

Categories:

,

Leave a Reply

Your email address will not be published. Required fields are marked *

Exit mobile version