blob: a1bb01fcda95e5d64fd26704574e1187d0156c7c [file] [log] [blame]
Andrew Geissler1e8b1642021-01-05 15:00:25 -06001[Unit]
2Description=Set host state to transition to off
3Wants=mapper-wait@-xyz-openbmc_project-state-host%i.service
4After=mapper-wait@-xyz-openbmc_project-state-host%i.service
5Wants=obmc-host-stop-pre@%i.target
6Before=obmc-host-stop-pre@%i.target
Andrew Geissler3ac78df2021-06-03 16:00:58 -05007Conflicts=obmc-host-startmin@%i.target
Andrew Geissler1e8b1642021-01-05 15:00:25 -06008
9[Service]
10Restart=no
11Type=oneshot
Andrew Geissler3ac78df2021-06-03 16:00:58 -050012RemainAfterExit=yes
Andrew Geissler1e8b1642021-01-05 15:00:25 -060013ExecStart=/bin/sh -c "busctl set-property `mapper get-service /xyz/openbmc_project/state/host%i` /xyz/openbmc_project/state/host%i xyz.openbmc_project.State.Host CurrentHostState s xyz.openbmc_project.State.Host.HostState.TransitioningToOff"
14
15[Install]
16WantedBy=obmc-host-stop@%i.target