Skip to content
This repository was archived by the owner on Jan 15, 2025. It is now read-only.
This repository was archived by the owner on Jan 15, 2025. It is now read-only.

Exporting OSTree commit to OCI does not maintain xattrs #655

Closed
@antheas

Description

@antheas

Part 2 of issue:
#654

As noted in the ostree-rs-ext readme, tar encoding used to have very poor characteristics for xattrs, which is why the format bare-split-xattrs exists for an OSTree repository, which maintains them.

This is not true anymore. The version of podman shipped in Ubuntu 2024 handles both SELinux and xattrs correctly.

The focus of this issue is that a quirk in the OSTree to OCI converter means that the xattrs of the files are not serialized to the tar stream.

This is not an issue during image deployment.

However, it does become an issue if I want to use rechunk on top of rechunk (e.g., extend a base image and then chunk it again), or deploy an OSTree image with future bootc.

As both will drop caps and ignore the xattrs in the OSTree repo of the image, which is discarded.

Therefore, ostree-rs-ext needs to encode those attributes into the tar stream, so that recent versions of podman can read and maintain them.

If a novice user extends an image with an old version of podman and drops the xattrs this is OK, as it is very unlikely that user will introduce files that need caps or special perms. Then, during deployment, rpm-ostree and bootc can reuse the xattrs and directory permissions from the bare-xattrs metadata. More advanced users will be aware of this requirement if they plan to rechunk their image.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions