From 79baa4968d27517a97f5c4db7d9ebf3b72b971cf Mon Sep 17 00:00:00 2001 From: Rich Mattes Date: Sat, 26 May 2018 16:24:20 -0400 Subject: [PATCH] Add documentation and networking dep to unit files Updated the unit file examples to add a dependency on the network-online.target systemd target to prevent mosquitto from starting without network connectivity. Added a documentation line to the unit files pointing to mosquitto manpages. Signed-off-by: Rich Mattes --- service/systemd/mosquitto.service.notify | 3 +++ service/systemd/mosquitto.service.simple | 3 +++ 2 files changed, 6 insertions(+) diff --git a/service/systemd/mosquitto.service.notify b/service/systemd/mosquitto.service.notify index 09a3e50d..8a0bda55 100644 --- a/service/systemd/mosquitto.service.notify +++ b/service/systemd/mosquitto.service.notify @@ -1,5 +1,8 @@ [Unit] Description=Mosquitto MQTT v3.1/v3.1.1 Broker +Documentation=man:mosquitto.conf(5) man:mosquitto(8) +After=network-online.target +Wants=network-online.target [Service] Type=notify diff --git a/service/systemd/mosquitto.service.simple b/service/systemd/mosquitto.service.simple index e1ab29a3..afef8ef3 100644 --- a/service/systemd/mosquitto.service.simple +++ b/service/systemd/mosquitto.service.simple @@ -1,5 +1,8 @@ [Unit] Description=Mosquitto MQTT v3.1/v3.1.1 Broker +Documentation=man:mosquitto.conf(5) man:mosquitto(8) +After=network-online.target +Wants=network-online.target [Service] ExecStart=/usr/sbin/mosquitto -c /etc/mosquitto/mosquitto.conf