Skip to content

Preserve permissions using upkg#1625

Merged
JavierMatosD merged 16 commits intomicrosoft:mainfrom
JavierMatosD:upkg_permissions
Apr 15, 2025
Merged

Preserve permissions using upkg#1625
JavierMatosD merged 16 commits intomicrosoft:mainfrom
JavierMatosD:upkg_permissions

Conversation

@JavierMatosD
Copy link
Copy Markdown
Contributor

Initial install:

image


After cache download:

image

Permissions not preserved!

Changing to zip contents…

Original Install:


image

Observe the write permissions.

Installing from binary cache:

image

Permissions preserved!

Comment thread src/vcpkg/binarycaching.cpp Outdated
Comment thread src/vcpkg/binarycaching.cpp
@JavierMatosD JavierMatosD requested a review from BillyONeal March 25, 2025 22:01
@BillyONeal
Copy link
Copy Markdown
Member

What happens if someone had already set up universal packages? Does this change invalidate all their caches or fall over if it sees an 'old world order' upkg?

Comment thread src/vcpkg/binarycaching.cpp Outdated
Comment thread src/vcpkg/binarycaching.cpp Outdated
@BillyONeal
Copy link
Copy Markdown
Member

What happens if someone had already set up universal packages? Does this change invalidate all their caches or fall over if it sees an 'old world order' upkg?

To clarify: This is x- and new-ish so I think it's OK if we break existing users, I just think we need to understand what to tell them

@JavierMatosD
Copy link
Copy Markdown
Contributor Author

What happens if someone had already set up universal packages? Does this change invalidate all their caches or fall over if it sees an 'old world order' upkg?

This will invalidate caches. Nothing should "fall over", it should just trigger a new upload / download.

Comment thread src/vcpkg/binarycaching.cpp Outdated
Comment thread src/vcpkg/binarycaching.cpp Outdated
Comment thread src/vcpkg/binarycaching.cpp Outdated
Comment thread src/vcpkg/binarycaching.cpp
@BillyONeal
Copy link
Copy Markdown
Member

Also can you describe how you tested this?

@JavierMatosD
Copy link
Copy Markdown
Contributor Author

Also can you describe how you tested this?

Its in the description #1625 (comment)

@BillyONeal
Copy link
Copy Markdown
Member

Its in the description #1625 (comment)

That's a screenshot showing it working, I mean, "before signing off on this I want to try it myself, how can I do that?"

@JavierMatosD
Copy link
Copy Markdown
Contributor Author

Its in the description #1625 (comment)

That's a screenshot showing it working, I mean, "before signing off on this I want to try it myself, how can I do that?"

I created an overlay port that installs an executable. I set up an asset cache, logged in, installed the overlay port. Then reinstalled it from the cache and inspected the permissions on the executable.

@BillyONeal BillyONeal closed this Apr 14, 2025
@BillyONeal BillyONeal reopened this Apr 14, 2025
@BillyONeal
Copy link
Copy Markdown
Member

Closing and reopening to force re-merge with #1648

Copy link
Copy Markdown
Member

@BillyONeal BillyONeal left a comment

Choose a reason for hiding this comment

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

This approval is contingent on an attestation that you tried the procedure mentioned in the PR description with the current code. (I normally wouldn't mention this but after the 1 revision which deleted the downloaded zip before extracting it coupled with our absolute inability to regression test this makes me paranoid)

@JavierMatosD JavierMatosD merged commit 63696ba into microsoft:main Apr 15, 2025
18 of 19 checks passed
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.

3 participants