Bug 2165483

Summary: mock is using wrong ownership for the result directory
Product: [Fedora] Fedora EPEL Reporter: Götz Waschk <goetz.waschk>
Component: mockAssignee: Copr Team <copr-team>
Status: NEW --- QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: epel9CC: copr-team, fabian.krack, jkeating, msuchy, philip.wyett, praiskup, williams
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 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 Götz Waschk 2023-01-30 08:59:43 UTC
Description of problem:

When you rebuild a package in mock on EL9, the result directory has the wrong group ownership, it should be owned by the mock group, but it is owned by the caller's primary group.


Version-Release number of selected component (if applicable): 3.5-1.el9


How reproducible:
always

Steps to Reproduce:
1. mock somepackage
2. ls -ld /var/lib/mock/*/result
3.

Actual results:
% ls -ld /var/lib/mock/slz-7-x86_64/result
drwxrwxr-x. 2 waschk dv 4096 30. Jan 09:53 /var/lib/mock/slz-7-x86_64/result


Expected results:
drwxrwxr-x. 2 waschk mock 4096 30. Jan 09:53 /var/lib/mock/slz-7-x86_64/result

Additional info:
This is different from the behaviour of mock 2.17-1.el7 on EL7.

Comment 1 Pavel Raiskup 2023-01-30 09:53:34 UTC
Thank you for the report.

Can you elaborate on why you need this fix, and what it breaks?

Comment 2 Götz Waschk 2023-01-30 10:42:53 UTC
This is a problem if another user with a different primary group is calling mock. Then he cannot write the results into this directory.