The adoption of Containers and microservice architectures has been amazing and speedy in the past few years. Docker is widely used runtime engine in the deployment of containerized applications in Kubernetes, Development environments and other container platforms. A recent utility called Podman provided as part of the libpod library was released to help you create and maintain containers.
The following tutorial will teach you how to install Podman on Amazon Linux and perform some basic commands with Podman. Podman is an open source, daemonless, Linux native tool created to ease finding, building, running, sharing and deployment of applications using Open Containers Initiative (OCI) Containers and Container Images.
Install Podman in Amazon Linux 2
Login to an instance of Amazon Linux 2 running in the cloud or in your on-prem infrastructure.
$ ssh root@myamazonlinux
Last login: Thu Oct 31 07:30:17 2024 from gateway
__| __|_ )
_| ( / Amazon Linux 2 AMI
___|\___|___|
https://aws.amazon.com/amazon-linux-2/
43 package(s) needed for security, out of 109 available
Run "sudo yum update" to apply all updates
Confirm OS is correct.
$ cat /etc/os-release
NAME="Amazon Linux"
VERSION="2"
ID="amzn"
ID_LIKE="centos rhel fedora"
VERSION_ID="2"
PRETTY_NAME="Amazon Linux 2"
ANSI_COLOR="0;33"
CPE_NAME="cpe:2.3:o:amazon:amazon_linux:2"
HOME_URL="https://amazonlinux.com/"
Update your OS
sudo yum -y update
sudo systemctl reboot
Disable Docker YUM repository:
sudo yum-config-manager --disable amzn2extra-docker
Enable EPEL repository on Amazon Linux 2:
sudo yum -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
Add the Kubic project project repository.
sudo curl -L -o /etc/yum.repos.d/devel:kubic:libcontainers:stable.repo https://download.opensuse.org/repositories/devel:/kubic:/libcontainers:/stable/CentOS_7/devel:kubic:libcontainers:stable.repo
sudo yum -y install yum-plugin-copr
Install Podman on Amazon Linux 2:
sudo yum -y copr enable lsm5/container-selinux
sudo yum -y install podman
All dependencies are installed automatically.
...
Transaction Summary
======================================================================================================================================================================================================
Install 1 Package (+27 Dependent packages)
Total download size: 70 M
Installed size: 174 M
Is this ok [y/d/N]: y
Confirm the installation of Podman on Amazon Linux 2 was successful.
$ podman version
Version: 5.3.0
API Version: 5.0.0
Go Version: go1.23.2
Built: Mon Mar 1 14:30:40 2021
OS/Arch: linux/amd64
CloudSpinx is here to help you streamline your tech stack, we deliver robust solutions tailored to your needs.