How to Install Podman on Debian 12

Are you worried about installing Podman on Debian 12? No need to worry at all!

Podman stands out for its security and flexibility. Unlike Docker, Podman doesn’t require a daemon to run, which reduces the attack surface. Plus, if you’re familiar with Docker, you’ll find Podman’s CLI commands quite similar.

This tutorial will explain the step-by-step instructions to install Podman on Debian 12.

How to Install Podman on Debian 12

If you’re running Debian 12, here’s a step-by-step guide to installing Podman:

Step 1: Update Your System

First of all, update the Debian system via the below command:

sudo apt update
Update Your System

This ensures that all your existing packages are up to date.

Step 2: Install Podman

Debian 12 includes Podman in its default repositories, so installation is straightforward. Let’s install Podman:

sudo apt install podman
install podman on debian 12

This command downloads and installs Podman along with its dependencies.

Step 3: Verify Installation

Once the installation is complete, you can verify that Podman is installed correctly by checking its version:

podman --version
verification installation podman on debian 12

You see the version number of Podman, confirming that the installation was successful.

Step 4: Basic Podman Commands

Now that Podman is installed, let’s go over a few basic commands to get you started:

  • Pulling an Image: For pulling the image through the container registry, utilize the below command:
  podman pull docker.io/library/alpine
Basic Podman Commands
  • Running a Container: For running the container from the pulled image:
  podman run -it alpine sh
  • List Running Containers: For listing all running containers, utilize:
  podman ps
  • Stopping a Container: To stop the running container, utilize:
  podman stop <container_id>

Step 5: Rootless Containers

One of Podman’s features is its support for rootless containers. For running Podman as a non-root user:

podman run -it alpine sh
run Podman on debian 12

This command runs the Alpine container as your current user, enhancing security by not requiring root privileges.

Conclusion

Installing Podman on Debian 12 is a straightforward process that opens up a world of possibilities for container management. To install Podman on Debian 12, update your system and install Podman using sudo apt install podman. With its security features and compatibility with Docker, Podman is an excellent choice for both new and experienced users.

By following these steps, you’ll have Podman up and running in no time, ready to streamline your container workflows.

Leave a Comment

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

Scroll to Top
Scroll to Top