Skip to content

Add support for Podman#251

Open
ccpcfrdc wants to merge 1 commit intocoroot:mainfrom
ccpcfrdc:add-podman-support
Open

Add support for Podman#251
ccpcfrdc wants to merge 1 commit intocoroot:mainfrom
ccpcfrdc:add-podman-support

Conversation

@ccpcfrdc
Copy link

@ccpcfrdc ccpcfrdc commented Oct 8, 2025

Add support for Podman containers as well.

@apollo13
Copy link
Contributor

With podman & systemd it is also common to run with --cgroups=split in which case you'd have:

/system.slice/app_name.service/libpod-payload-cc316b3065798e96c30dcfc708f7a7dda1b2d78e552364002d2e49a3100ef3ef

as well, would be nice if that would also get picked up as podman.

}

// Try to find log file
logPath := fmt.Sprintf("/var/lib/containers/storage/overlay-containers/%s/userdata/ctr.log", containerID)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The default for podman nowadays is --journal-driver=journald -- there won't be any logfiles around.

Detect Podman/libpod containers via cgroup patterns:
- rootful: machine.slice/libpod-<ID>.scope
- rootless: user.slice/.../libpod-<ID>.scope
- --cgroups=split: system.slice/<svc>/libpod-payload-<ID>
- conmon processes are filtered (like crio-conmon)

Use Podman REST API via Unix socket for container inspection,
following the same http.Client pattern as CRI-O.

Log collection supports both journald (Podman default) and
json-file log drivers via the existing journald reader and
file tail reader respectively.

Authored by LastCoder | e6d8e0a6-31aa-49de-8456-dc6577890436
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants