Skip to content

🐛 util/image: unset PAXRecords and Xattrs when applying files #1823

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

Merged

Conversation

joelanford
Copy link
Member

Description

If a catalog or bundle image contains files with xattrs, that can cause the controller to fail to unpack the image. This PR unsets those attributes to avoid permission errors when writing files to disk.

Reviewer Checklist

  • API Go Documentation
  • Tests: Unit Tests (and E2E Tests, if appropriate)
  • Comprehensive Commit Messages
  • Links to related GitHub Issue(s)

@joelanford joelanford requested a review from a team as a code owner February 28, 2025 02:53
Copy link

netlify bot commented Feb 28, 2025

Deploy Preview for olmv1 ready!

Name Link
🔨 Latest commit 83cf868
🔍 Latest deploy log https://app.netlify.com/sites/olmv1/deploys/67c127272027ef00082075bc
😎 Deploy Preview https://deploy-preview-1823--olmv1.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@joelanford joelanford force-pushed the fix-image-apply-xattr branch from 0e4357d to 83cf868 Compare February 28, 2025 03:01
Copy link

codecov bot commented Feb 28, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 68.44%. Comparing base (a6de9f9) to head (83cf868).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1823      +/-   ##
==========================================
+ Coverage   68.43%   68.44%   +0.01%     
==========================================
  Files          63       63              
  Lines        5132     5134       +2     
==========================================
+ Hits         3512     3514       +2     
  Misses       1390     1390              
  Partials      230      230              
Flag Coverage Δ
e2e 51.57% <100.00%> (+0.02%) ⬆️
unit 56.03% <100.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@camilamacedo86 camilamacedo86 left a comment

Choose a reason for hiding this comment

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

I think the proposed solution is a good approach.
We address the problem when unpacking the image, and from that point on, it's up to the solution itself to determine whether it has the necessary capabilities to run whatever it needs to. We are not modifying it at all.

So, if my understanding is correct:

/lgtm
/approve

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Feb 28, 2025
@joelanford joelanford added this pull request to the merge queue Feb 28, 2025
Merged via the queue into operator-framework:main with commit 9e2f28c Feb 28, 2025
20 checks passed
@joelanford joelanford deleted the fix-image-apply-xattr branch February 28, 2025 17:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants