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

[Question/Feature] Is IgnorePkg a viable workaround for safe overlay upgrades? #29

Open
erisdev opened this issue Jan 31, 2023 · 6 comments
Labels
enhancement New feature or request help wanted Extra attention is needed question Further information is requested

Comments

@erisdev
Copy link

erisdev commented Jan 31, 2023

As per the wiki, pacman.conf has IgnorePkg to prevent upgrading certain packages. If one were to add all the Steam OS default installed packages to this list, would it be safe to run pacman -Su on the overlay, or is there some other issue that I'm not aware of? Obviously, I'm hesitant to simply fuck around and find out.

@erisdev erisdev changed the title [Question] Is IgnorePkg a viable workaround for safe overlay upgrades? [Question/Feature] Is IgnorePkg a viable workaround for safe overlay upgrades? Jan 31, 2023
@ValShaped
Copy link
Owner

That could very well work, yeah! Good idea!

@ValShaped
Copy link
Owner

I looked into it further, and setting IgnorePkg would require touching /etc/pacman.conf. As /etc/ is itself an overlay, that would copy it into /var/lib/overlay/etc/upper, and when the Deck updates, that file will desync from the one in the base filesystem.

We can't remount /etc/ without crashing everything, either, since that's where all the config files are.

The only other options are to wrap pacman, or create a custom package manager interface based on libalpm, which I'm diametrically apposed to doing (since that would defeat the purpose of using overlays in the first place -- and at that point you might as well just add ~/.local/some_dir to $PATH, and use your custom pacman config to install packages there.)

If you know of a solution that doesn't require reimplementing or wrapping pacman, I'm all up for it, otherwise I don't know what to do.

@ValShaped ValShaped added enhancement New feature or request help wanted Extra attention is needed question Further information is requested labels Feb 6, 2023
@erisdev
Copy link
Author

erisdev commented Feb 6, 2023

Would it be possible to be a little rude and say that rwfus "owns" /etc/pacman.conf and re-inject a freshly generated IgnorePkg into a clean copy of the file before each mount? Or maybe only when it detects that the OS image has been updated, if that's possible?

@ValShaped
Copy link
Owner

ValShaped commented Feb 7, 2023

The problem there is getting at the original file without unmounting /etc. Writing directly into an overlayfs upper dir while it's mounted is undefined behavior, so we can't just delete the modified file at runtime (though I've never had it fail in my testing)

(Rwfus can't start before SteamOS-Offload, since it relies on Offload for other things)

@erisdev
Copy link
Author

erisdev commented Feb 7, 2023

Gotcha. the /etc overlay doesn't belong to rwfus, then? That makes sense.

Yeah, I'm not sure what else I'd have for this, but I'll let you know if I have a stroke of genius. I'm fairly familiar with Arch, but I haven't really dug too deep into the workings of Steam OS.

@ValShaped
Copy link
Owner

Yep, the /etc overlay is handled by SteamOS Offload (which is part of the package steamos-customizations, iirc)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants