Allow empower group
This will need to be patched into setup.
This commit is contained in:
parent
a0acca210d
commit
044cff4700
2 changed files with 8 additions and 4 deletions
|
|
@ -1116,12 +1116,13 @@ mv -v %{buildroot}/usr/sbin/* %{buildroot}%{_bindir}/
|
|||
# We skip this on upstream builds so that new users and groups
|
||||
# can be added without breaking the build.
|
||||
%if 0%{?fedora} >= 43
|
||||
%{python3} %{SOURCE4} /usr/lib/sysusers.d/setup.conf %{buildroot}/usr/lib/sysusers.d/basic.conf
|
||||
IGNORED=empower \
|
||||
%{python3} %{SOURCE4} /usr/lib/sysusers.d/setup.conf %{buildroot}/usr/lib/sysusers.d/basic.conf
|
||||
%else
|
||||
%{python3} %{SOURCE4} /usr/lib/sysusers.d/20-setup-{users,groups}.conf %{buildroot}/usr/lib/sysusers.d/basic.conf
|
||||
%endif
|
||||
%endif
|
||||
rm %{buildroot}/usr/lib/sysusers.d/basic.conf
|
||||
sed -n -r -i '1,7p; /can .do.|empower/p' %{buildroot}/usr/lib/sysusers.d/basic.conf
|
||||
%endif
|
||||
|
||||
# Disable sshd_config.d/20-systemd-userdb.conf for now.
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
#!/usr/bin/python
|
||||
|
||||
import os
|
||||
import sys
|
||||
|
||||
def parse_sysusers_file(filename):
|
||||
|
|
@ -30,7 +31,9 @@ for arg in sys.argv[1:-1]:
|
|||
|
||||
basic_users, basic_groups = parse_sysusers_file(sys.argv[-1])
|
||||
|
||||
if d := basic_users - setup_users:
|
||||
ignored = set(os.getenv('IGNORED', '').split())
|
||||
|
||||
if d := basic_users - setup_users - ignored:
|
||||
exit(f'We have new users: {d}')
|
||||
if d := basic_groups - setup_groups:
|
||||
if d := basic_groups - setup_groups - ignored:
|
||||
exit(f'We have new groups: {d}')
|
||||
|
|
|
|||
Loading…
Reference in a new issue