スキル一覧に戻る
knoopx

podman

by knoopx

pi.ai config

2🍴 0📅 2026年1月21日
GitHubで見るManusで実行

SKILL.md


name: podman description: Manage containers, pods, and images as a daemonless, rootless alternative to Docker. Use when running containerized applications, building images, grouping containers into pods, or performing cleanup.

Podman Skill

Podman is a tool for managing OCI containers and pods. It is daemonless and can run containers as a non-root user.

Container Management

Basic Lifecycle

# Run a container (detached)
podman run -d --name my-app alpine sleep 1000

# List running containers
podman ps

# List all containers (including stopped ones)
podman ps -a

# Stop and remove a container
podman stop my-app
podman rm my-app

# Inspect container details
podman inspect my-app

Logs and Execution

# View container logs (non-interactive)
podman logs my-app

# Execute a command in a running container
podman exec my-app ls /app

Image Management

# Pull an image
podman pull alpine:latest

# List local images
podman images

# Build an image from a Containerfile (or Dockerfile)
podman build -t my-custom-image .

# Remove an image
podman rmi my-custom-image

Pods (Unique to Podman)

Pods allow grouping multiple containers together so they share the same network namespace (localhost).

# Create a pod
podman pod create --name my-stack -p 8080:80

# Run a container inside a pod
podman run -d --pod my-stack --name nginx nginx

# List pods
podman pod ps

Maintenance and Cleanup

# Remove all stopped containers, unused networks, and dangling images
podman system prune -f

# Show disk usage by containers/images
podman system df

Headless / Non-Interactive Tips

  • Force Flag: Use -f or --force with rm, rmi, and prune to avoid confirmation prompts.
  • Detached Mode: Always use -d for long-running services to prevent the command from hanging. For interactive sessions, use: tmux new -d 'podman run -it --name my-app alpine sh'
  • Rootless: Podman runs in rootless mode by default for the current user. Ensure subuid/subgid are configured if running complex workloads.
  • Docker Compatibility: Most docker commands can be prefixed with podman instead.

Volumes

# Create a volume
podman volume create my-data

# Run container with a volume mount
podman run -v my-data:/data:Z alpine ls /data

Note: Use :Z or :z suffix for volume mounts on systems with SELinux to automatically relabel files.

  • nix: Use Nix to create development environments that can be integrated with Podman containers.

スコア

総合スコア

50/100

リポジトリの品質指標に基づく評価

SKILL.md

SKILL.mdファイルが含まれている

+20
LICENSE

ライセンスが設定されている

0/10
説明文

100文字以上の説明がある

0/10
人気

GitHub Stars 100以上

0/15
最近の活動

3ヶ月以内に更新がある

0/10
フォーク

10回以上フォークされている

0/5
Issue管理

オープンIssueが50未満

+5
言語

プログラミング言語が設定されている

+5
タグ

1つ以上のタグが設定されている

0/5

レビュー

💬

レビュー機能は近日公開予定です