Skip to content
This repository was archived by the owner on Feb 10, 2021. It is now read-only.
This repository was archived by the owner on Feb 10, 2021. It is now read-only.

Libary calls do not work #85

Description

@Pilzington

I installed podman and the python podman library. But I does not show any images or containers:

$ podman version
Version:      2.0.4
API Version:  1
Go Version:   go1.14.4
Built:        Thu Jan  1 01:00:00 1970
OS/Arch:      linux/amd64

$ podman images
REPOSITORY                TAG     IMAGE ID      CREATED       SIZE
docker.io/library/nginx   latest  4bb46517cac3  7 days ago    137 MB
docker.io/library/alpine  latest  a24bb4013296  2 months ago  5.85 MB

$ podman ps
CONTAINER ID  IMAGE                           COMMAND               CREATED            STATUS                PORTS   NAMES
96f979df67f8  docker.io/library/nginx:latest  nginx -g daemon o...  About an hour ago  Up About an hour ago          eager_galileo

My Python Script:

#!/usr/bin/env python3

import podman

with podman.Client() as client:
    print(client.images.list())
    for image in client.images.list():
        print(image)
    print(client.containers.list())
    for container in client.containers.list():
        print(container)

Output:

<generator object Images.list at 0x7f41cbd344c0>
<generator object Containers.list at 0x7f41cbd344c0>

Am I doing anything wrong? I installed it first following this blog post. Does this break anything due to the new API. Also is there a documentation anywhere?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions