Bug 1132762

Summary: RFE: Support systemd-nspawn as a chroot replacement for mock
Product: [Fedora] Fedora Reporter: Craig Ringer <craig>
Component: mockAssignee: Miroslav Suchý <msuchy>
Status: CLOSED NEXTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: unspecified    
Version: rawhideCC: jdisnard, mebrown, msimacek, msuchy, praiskup, williams
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Other   
Whiteboard:
Fixed In Version: mock-1.2.0 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-10-12 21:18:10 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Craig Ringer 2014-08-22 03:06:40 UTC
It'd be extremely useful to permit mock to run under systemd-nspawn, instead of chroot.

Notably, this would let mock be used to run simple package test scripts that could start and stop daemons, which isn't currently possible under mock with systemd.

This is just down as "hey, this'd be nice".

Comment 1 Miroslav Suchý 2014-08-22 07:29:42 UTC
Systemd is not present on RHEL6 (which we still support), but yes - it would be nice.

Comment 2 Miroslav Suchý 2014-10-01 19:31:24 UTC
Implemeted as f05982c.

in py/mockbuild/util.py is variable:
  USE_NSPAWN = True
when set to False, mock will use old code for classic chroot.
Spec file substitute that for EL6 builds.

Comment 3 Miroslav Suchý 2014-10-01 20:38:04 UTC
One additonal commit b792207.

And I find that some src.rpm have assert on building under root user.
I will try to add user into that container.

Comment 4 Miroslav Suchý 2014-10-09 09:19:37 UTC
One more commit e6017d3 with uid handling.

Comment 5 Miroslav Suchý 2014-10-12 21:18:10 UTC
Fixed in mock-1.2.0, which just landed in rawhide.