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

Support managing system in a chroot (bsc#1199840) #1258

Merged
merged 2 commits into from
May 24, 2022
Merged

Conversation

lslezak
Copy link
Member

@lslezak lslezak commented May 23, 2022

Problem

When running YaST in a container we need to somehow detect that YaST should manage the system mounted in the /mnt and not the container itself.

bsc#1199840

Details

Originally I wanted to detect that we are running in a container, but that's too specific. It should be more generic, in theory you could run YaST in a chroot or using a Live medium. Or you could manage the container itself, not the host system.

Solution

The target system needs to be set from the outside, YaST itself cannot detect that easily and reliably. The easiest way is to set an environment variable with the location of the mounted target system.

Testing

  • Tested manually
  • The change will be followed by updated yast2-registration package which will use the new methods

@coveralls
Copy link

coveralls commented May 23, 2022

Coverage Status

Coverage increased (+0.006%) to 41.641% when pulling 3639dbe on chroot_management into 979ae92 on master.

@mvidner
Copy link
Member

mvidner commented May 24, 2022

Just a clickable reference to WFM.scr_root.

@lslezak lslezak merged commit 61b204e into master May 24, 2022
@lslezak lslezak deleted the chroot_management branch May 24, 2022 13:21
@yast-bot
Copy link
Contributor

✔️ Public Jenkins job #370 successfully finished
✔️ Created OBS submit request #978975

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.

5 participants