Podman:无守护进程容器管理工具
一款管理 OCI 容器、镜像、卷和 Pod 的命令行工具,支持无 root 运行,兼容 Docker CLI。
- 浏览
- 8
- 访问
- 0
- 下载
- 0
- Stars
- 33,399
- 版本
- v6.2.1
- 平台
- Linux、macOS、Windows
详细介绍
项目简介
Podman(POD MANager)是一款用于管理容器、容器镜像、挂载卷以及由容器组成的 Pod 的工具。它基于同仓库中的 libpod 库,该库提供管理容器、Pod、容器镜像和卷的 API。
Podman 在 Linux 上运行容器,也可以借助 Podman 管理的虚拟机在 Mac 和 Windows 上使用。它不依赖常驻的管理守护进程,因此空闲时资源占用更低、安全性更好。
主要功能
- 支持多种容器镜像格式,包括 OCI 与 Docker 镜像。
- 完整的镜像管理:从多种来源拉取(含信任与校验)、通过 Containerfile 或 Dockerfile 构建、推送到镜像仓库及其他存储后端。
- 完整的容器生命周期管理:创建(从镜像或解压的根文件系统)、运行、检查点与恢复(通过 CRIU)、删除。
- 使用 Netavark 管理容器网络。
- 支持 Pod,即共享资源并一起管理的一组容器。
- 支持以非 root 或其他高权限身份运行容器和 Pod,并提供容器与 Pod 的资源隔离。
- 提供兼容 Docker 的 CLI 接口,既可在本地运行容器,也可操作远程系统。
- 提供 REST API,既包含兼容 Docker 的接口,也包含暴露 Podman 高级功能的改进接口。
- 通过
podman machine启动的虚拟机,支持在 Windows 和 Mac 上运行。
安装与使用
安装方式请参考项目提供的安装说明(install.md)以及官网的安装指南。安装完成后,可直接使用 Podman 命令管理容器与镜像;从 Docker 迁移时可参考项目中的命令对照表(transfer.md),其中列出了 Docker 命令与 Podman 对应命令。
远程客户端的使用方法见 remote client 教程。
注意事项
- 无 root 模式(Rootless)下,容器权限不会超过启动它的用户;部分限制可通过
--privileged等方式放宽。 - 无 root 运行前,管理员可能需要进行少量配置,具体步骤见 rootless 教程。
- 项目每年发布 4 次大版本或次版本(2 月、5 月、8 月、11 月第二周),补丁版本发布更频繁;通常只有最新版本获得上游支持,特殊情况会提供 LTS 版本。
- 若发现安全问题,请不要通过 GitHub issue、邮件列表或 IRC 公开报告,而应发送邮件至
[email protected]。 - 专门的镜像签名与推送、Kubernetes CRI 接口支持不在本项目范围内,分别由 Skopeo 和 CRI-O 负责。
相关项目
Podman Desktop 为 Linux、Windows 和 Mac 提供 Podman 与 Kubernetes 的本地开发环境,是功能完整的桌面图形前端;在非 Linux 系统上它使用 podman machine 后端运行容器。
本作品整理自 GitHub 开源项目 podman-container-tools/podman,原作者 @podman-container-tools,许可证 Apache-2.0。中文介绍由 AI 根据项目 README 整理,以原仓库为准。
更新记录
- v6.2.1当前版本
### Bugfixes - Fixed a bug where ConfigMaps and Secrets mounted as executable were not being able to be executed immediately on pod launch when using `podman kube play`. - Fixed a bug where the Docker compatible image inspect responses returning an empty author for images with an author set. - Fixed a bug where the podman service did not use the correct server configured temporary directory for remote image builds ([#20839](https://github.com/podman-container-tools/podman/issues/20839)). - Fixed a bug where `--userns=nomap` sets the wrong supplementary group ([#30261](https://github.com/podman-container-tools/podman/issues/30261)). - Fixed a bug where the Docker compatible network inspect and list endpoints are failing when a network has no gateway. - Fixed a bug where `podman pod clone` would fail when it has no infra container ([#30340](https://github.com/podman-container-tools/podman/issues/30340)). - Fixed a bug where `podman-remote manifest push --compression-level` had no effect.
- v6.2.0
修复三个安全漏洞:auto-update 被镜像标签欺骗、镜像可绕过 Digest 与签名校验、默认 seccomp 策略的 socket 拒绝规则可被绕过;podman push 新增 --platform,kube play 新增 --validate、--label、--multiple-pods 等选项。
评论