[SPECfile cleanup] start using %{unitdir} macro
Related: RHEL-31421
This commit is contained in:
parent
e2664502af
commit
51a41a0520
@ -70,13 +70,13 @@ cmake -B %_vpath_builddir -LAH
|
|||||||
# Fedora downstream packaging historically used "garbd" name for the service.
|
# Fedora downstream packaging historically used "garbd" name for the service.
|
||||||
#
|
#
|
||||||
# Let's stick with the Fedora legacy naming, AND provide an alias to the Galera upstream name
|
# Let's stick with the Fedora legacy naming, AND provide an alias to the Galera upstream name
|
||||||
mv %{buildroot}/usr/lib/systemd/system/garb.service %{buildroot}/usr/lib/systemd/system/garbd.service
|
mv %{buildroot}%{_unitdir}/garb.service %{buildroot}%{_unitdir}/garbd.service
|
||||||
sed -i 's/Alias=garbd.service/Alias=garb.service/g' %{buildroot}/usr/lib/systemd/system/garbd.service
|
sed -i 's/Alias=garbd.service/Alias=garb.service/g' %{buildroot}%{_unitdir}/garbd.service
|
||||||
|
|
||||||
# PATCH 2:
|
# PATCH 2:
|
||||||
# Fix the hardcoded paths
|
# Fix the hardcoded paths
|
||||||
# In the Systemd service file:
|
# In the Systemd service file:
|
||||||
sed -i 's;/usr/bin/garb-systemd;/usr/sbin/garb-systemd;g' %{buildroot}/usr/lib/systemd/system/garbd.service
|
sed -i 's;/usr/bin/garb-systemd;/usr/sbin/garb-systemd;g' %{buildroot}%{_unitdir}/garbd.service
|
||||||
# In the wrapper script:
|
# In the wrapper script:
|
||||||
sed -i 's;/usr/bin/garbd;/usr/sbin/garbd;g' %{buildroot}/usr/sbin/garb-systemd
|
sed -i 's;/usr/bin/garbd;/usr/sbin/garbd;g' %{buildroot}/usr/sbin/garb-systemd
|
||||||
|
|
||||||
@ -103,7 +103,7 @@ sed -i 's;/usr/bin/garbd;/usr/sbin/garbd;g' %{buildroot}/usr/sbin/garb-systemd
|
|||||||
## in particular on systems using NFS or running containers. Allocate a user ID
|
## in particular on systems using NFS or running containers. Allocate a user ID
|
||||||
## specific to this service, either statically via systemd-sysusers or dynamically
|
## specific to this service, either statically via systemd-sysusers or dynamically
|
||||||
## via the DynamicUser= service setting.
|
## via the DynamicUser= service setting.
|
||||||
sed -i 's/User=nobody/User=garb/g' %{buildroot}/usr/lib/systemd/system/garbd.service
|
sed -i 's/User=nobody/User=garb/g' %{buildroot}%{_unitdir}/garbd.service
|
||||||
|
|
||||||
|
|
||||||
%check
|
%check
|
||||||
|
Loading…
Reference in New Issue
Block a user