Repository navigation
[Backport 2.35-maintenance] packaging/scripted-installer: Only chown pre-existing files when needed - #16790
Merged
internal-nix-ci[bot] merged 3 commits intoNov 9, 2026
Conversation
Partially reverts 9533d33, modulo the 0:0 vs 0:nixbld ownership. I got a bit overzealous deleting code and it did turn out load-bearing. So apparently not even root can chown /nix/.Trashes on macOS (╯°□°)╯︵ ┻━┻ This is quite impossible to test in CI too? Because of #13719, we leave /nix/store/* objects alone that have nixbld group ownership for now. Chowning them to root might be impossible because of App Management on macOS (e.g. xcode store objects). Also older installers messed this part up. /nix/var/nix/builds/* is ignored entirely. (cherry picked from commit db97f25)
The -n trick doesn't work on macOS sadly. So instead we can delete the bootstrap closure and replace it afterwards. --load-db re-registers existing valid paths so it should be fine. (cherry picked from commit 2c40b63)
App Management also denies changing the mode of apps in the store. If the user is running the installer over an existing install this might (and will) blow up if they have apps in the store. (cherry picked from commit 57d11f7)
4 of 6 tasks
1 task
1 task
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Automatic backport to
2.35-maintenance, triggered by a label in #16785.