24 lines
1.3 KiB
SYSTEMD
24 lines
1.3 KiB
SYSTEMD
[Unit]
|
|
Description=Podman pod-home-assistant.service
|
|
Wants=network-online.target
|
|
After=network-online.target
|
|
RequiresMountsFor=
|
|
#Requires=container-hass-app.service container-hass-zigbee2mqtt.service container-hass-mosquitto.service
|
|
#Before=container-hass-app.service container-hass-zigbee2mqtt.service container-hass-mosquitto.service
|
|
Requires=container-hass-app.service container-hass-zigbee2mqtt.service container-hass-mosquitto.service container-hass-postgres.service
|
|
Before=container-hass-app.service container-hass-zigbee2mqtt.service container-hass-mosquitto.service container-hass-postgres.service
|
|
|
|
[Service]
|
|
Environment=PODMAN_SYSTEMD_UNIT=%n
|
|
Restart=on-failure
|
|
TimeoutStopSec=70
|
|
ExecStartPre=/bin/rm -f %t/pod-home-assistant.pid %t/pod-home-assistant.pod-id
|
|
ExecStartPre=/usr/bin/podman pod create --infra-conmon-pidfile %t/pod-home-assistant.pid --pod-id-file %t/pod-home-assistant.pod-id --network=host --name home-assistant --replace
|
|
ExecStart=/usr/bin/podman pod start --pod-id-file %t/pod-home-assistant.pod-id
|
|
ExecStop=/usr/bin/podman pod stop --ignore --pod-id-file %t/pod-home-assistant.pod-id -t 10
|
|
ExecStopPost=/usr/bin/podman pod rm --ignore -f --pod-id-file %t/pod-home-assistant.pod-id
|
|
PIDFile=%t/pod-home-assistant.pid
|
|
Type=forking
|
|
|
|
[Install]
|
|
WantedBy=default.target |