Blame SOURCES/rhcd-stop.service.in

dfd011
# This file is part of rhc.
dfd011
#
dfd011
# Any changes made to this file will be overwritten during a software update. To
dfd011
# override a parameter in this file, create a drop-in file, typically located at
dfd011
# /etc/systemd/system/rhcd-stop.service.d/override.conf. Put the desired
dfd011
# overrides in that file and reload systemd. The next time this service is run
dfd011
# (either manually or via a systemd timer), the overridden values will be in
dfd011
# effect.
dfd011
#
dfd011
# For more information about systemd drop-in files, see systemd.unit(5).
dfd011
dfd011
[Unit]
dfd011
Description=Automatically stop rhcd when rhsm cert does not exists
dfd011
ConditionPathExists=!@sysconfdir@/pki/consumer/cert.pem
dfd011
dfd011
[Service]
dfd011
Type=simple
dfd011
ExecStart=/bin/systemctl stop rhcd.service
dfd011
ExecStopPost=/bin/systemctl unmask --now rhcd.path
dfd011
ExecStopPost=/bin/systemctl start rhcd.path