Blame SOURCES/rhcd-stop.service.in

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