Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ansible: Fix podman socket SELinux context on AWS #631

Merged
merged 1 commit into from
Dec 6, 2024
Merged

Conversation

martinpitt
Copy link
Member

@martinpitt martinpitt commented Dec 6, 2024

On Fedora CoreOS, SELinux wants the socket path in /run, while on Fedora
40 (on our PSI runners) it wants to go via /var/run, due to the
conflicting "extra_varrun" custom policy that Fedora installs for
migration.

Adjust the policy for /run (see [1] and bump priority to avoid
conflicting with extra_varrun.

[1] https://discussion.fedoraproject.org/t/f40-change-proposal-move-var-run-selinux-policy-entries-to-run-self-contained/100171


See https://github.com/orgs/cockpit-project/projects/4/?pane=issue&itemId=69115598 . Tested on PSI and AWS.

@martinpitt martinpitt marked this pull request as draft December 6, 2024 13:42
@martinpitt
Copy link
Member Author

Argh, retried with fresh deployment, and still broken. 🤯

@martinpitt
Copy link
Member Author

This works on Fedora CoreOS, but not on Fedora 40 rpm on PSI:

      /var/run/podman/podman.sock    system_u:object_r:container_file_t:s0
      /run/podman/podman.sock    system_u:object_r:container_file_t:s0

🤯

On Fedora CoreOS, SELinux wants the socket path in /run, while on Fedora
40 (on our PSI runners) it wants to go via /var/run, due to the
conflicting "extra_varrun" custom policy that Fedora installs for
migration.

Adjust the policy for /run (see [1] and bump priority to avoid
conflicting with extra_varrun.

[1] https://discussion.fedoraproject.org/t/f40-change-proposal-move-var-run-selinux-policy-entries-to-run-self-contained/100171
@martinpitt martinpitt marked this pull request as ready for review December 6, 2024 15:14
@martinpitt
Copy link
Member Author

Finally! This works. Completely coincidentally, that will also help me for https://issues.redhat.com/browse/RHEL-70238

@martinpitt martinpitt requested a review from jelly December 6, 2024 15:14
@martinpitt martinpitt merged commit 7d93ace into main Dec 6, 2024
3 checks passed
@martinpitt martinpitt deleted the selinux branch December 6, 2024 15:33
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