From f0ff0e1b37ed19477f1349637fd36c55400a2143 Mon Sep 17 00:00:00 2001 From: Nils Koenig Date: Thu, 19 Oct 2023 17:56:03 +0200 Subject: [PATCH] Use systemd-sysusers to create vhostmd user See also BZ 2095483wq https://bugzilla.redhat.com/show_bug.cgi?id=2095483 --- vhostmd.spec | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/vhostmd.spec b/vhostmd.spec index 30e89e4..95f39a4 100644 --- a/vhostmd.spec +++ b/vhostmd.spec @@ -125,11 +125,7 @@ rm $RPM_BUILD_ROOT%{_datadir}/vhostmd/scripts/pagerate.pl %pre # UID:GID 112:112 reserved, see RHBZ#534109. -getent group vhostmd >/dev/null || groupadd -g 112 -r vhostmd -getent passwd vhostmd >/dev/null || \ -useradd -u 112 -r -g vhostmd -d %{_datadir}/vhostmd -s /sbin/nologin \ --c "Virtual Host Metrics Daemon" vhostmd -exit 0 +%sysusers_create_inline u vhostmd 112 "Virtual Host Metrics Daemon" %{_datadir}/vhostmd /sbin/nologin %post