Skip to main content

podman-py

PyPI Latest Version

This python package is a library of bindings to use the RESTful API of Podman. It is currently under development and contributors are welcome!

Installation

pip install podman

Documentation: https://podman-py.readthedocs.io/en/latest/

Source Code: https://github.com/containers/podman-py


Dependencies

  • For runtime dependencies, see [dependencies] in pyproject.toml
  • For testing and development dependencies, see [project.optional.dependencies] in pyproject.toml
    • The package is split in [progress_bar], [docs], and [test]

Example usage

"""Demonstrate PodmanClient."""
import json
from podman import PodmanClient

# Provide a URI path for the libpod service.  In libpod, the URI can be a unix
# domain socket(UDS) or TCP.  The TCP connection has not been implemented in this
# package yet.

uri = "unix:///run/user/1000/podman/podman.sock"

with PodmanClient(base_url=uri) as client:
    version = client.version()
    print("Release: ", version["Version"])
    print("Compatible API: ", version["ApiVersion"])
    print("Podman API: ", version["Components"][0]["Details"]["APIVersion"], "\n")

    # get all images
    for image in client.images.list():
        print(image, image.id, "\n")

    # find all containers
    for container in client.containers.list():
        # After a list call you would probably want to reload the container
        # to get the information about the variables such as status.
        # Note that list() ignores the sparse option and assumes True by default.
        container.reload()
        print(container, container.id, "\n")
        print(container, container.status, "\n")

        # available fields
        print(sorted(container.attrs.keys()))

    print(json.dumps(client.df(), indent=4))

Contributing

See CONTRIBUTING.md

Metadata

Release files for podman 5.8.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for podman 5.8.0
File Size Uploaded
podman-5.8.0.tar.gz 121.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for podman 5.8.0
File Interpreter ABI Platform
podman-5.8.0-py3-none-any.whl Python 3 none any Details

Total release size: 216.1 kB

Release files / podman-5.8.0.tar.gz

Download URL podman-5.8.0.tar.gz
Size 121.6 kB
Tags Source
SHA-256 checksum
How to use checksums
bc39b77f4a6a0598bbe860d199e0d54ef2ec551131ae7eab66f0557c43331fb3
BLAKE2b-256 checksum
How to use checksums
18f1ea8988ff2085d1a898f7f27b7fa26a5b5e296949c6ef4df26ebc2be1aac0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Mar 25, 2026.

Transparency log

Release files / podman-5.8.0-py3-none-any.whl

Download URL podman-5.8.0-py3-none-any.whl
Size 94.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
0c0383386fc926e15b58890a727d8bb53b0c42730a5c610db391bfd20310ceeb
BLAKE2b-256 checksum
How to use checksums
1e0a648704ca7f70a44a407b556eda86fccd8cafcb060de90c884d66a7389f36
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Mar 25, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

5.8.0 This release

2 release files

5.7.0

2 release files

5.6.0

2 release files

5.5.0

2 release files

5.4.0

2 release files

5.2.0

2 release files

5.0.0

2 release files

4.9.0

2 release files

4.8.2

2 release files

4.8.1

2 release files

4.7.0

2 release files

4.6.0

2 release files

4.5.1

2 release files

4.5.0

2 release files

4.4.1

2 release files

4.4.0

2 release files

4.3.0

2 release files

4.2.0

2 release files

4.0.1

2 release files

4.0.0

2 release files

3.2.1

2 release files

3.2.0

2 release files

1.6.0

2 release files

0.0.3

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page