🦭
Container Platform

Podman

Daemonless container engine — Docker-compatible CLI

🐧 Linux🍎 Mac🪟 Windows📋 Quick reference →
Reviewed: Tested on: Kubernetes 1.29 · Terraform 1.8 · Ubuntu 22.04

What is this?

Podman runs containers like Docker but without a background daemon — often used as a Docker alternative.

📥

Step 01

Install Podman

(01)Install

Linux
1sudo apt-get install -y podman
2# RHEL: sudo dnf install -y podman
⚙️

Step 02

Configure Podman

(01)Docker-compatible alias

Linux
1podman run hello-world
2# Optional alias:
3echo 'alias docker=podman' >> ~/.bashrc
4podman compose up -d

Step 03

Verify

(01)Version

Linux
1podman --version
2podman ps

Step 04

Manage

(01)Commands

Linux
1podman ps -a
2podman build -t myapp .
3podman compose up -d

📋Config templates

2 YAML templates for Podman. Copy and deploy after setup.

2 ready-to-copy templates. Expand one, copy the YAML, then run the deploy commands.

docker-compose.yaml

PostgreSQL database + Flask app with env file and volume persistence

yaml
1version: "3.9"
2
3services:
4 db:
5 image: postgres:15-alpine
6 environment:
7 POSTGRES_DB: dukaan_db
8 POSTGRES_USER: dukaan
9 POSTGRES_PASSWORD: dukaan123
10 ports:
11 - "5432:5432"
12 volumes:
13 - pgdata:/var/lib/postgresql/data
14
15 app:
16 build: .
17 ports:
18 - "5000:5000"
19 env_file:
20 - .env
21 depends_on:
22 - db
23
24volumes:
25 pgdata:

Dockerfile

Flask application container image

dockerfile
1FROM python:3.12-slim
2WORKDIR /app
3COPY requirements.txt .
4RUN pip install --no-cache-dir -r requirements.txt
5COPY . .
6EXPOSE 5000
7CMD ["python", "app.py"]
📄

Step 01

Run with Docker Compose

(01)Build and start services

Linux
1cd your-project/
2docker compose up -d --build
3docker compose ps
4docker compose logs -f app

(02)Stop and clean up

Linux
1docker compose down
2docker compose down -v # remove volumes