From 3ae242fa5f1858e5b229683ce021e8e6702cc8e7 Mon Sep 17 00:00:00 2001 From: Fabio Alessandro Locati <77888+Fale@users.noreply.github.com> Date: Mon, 19 Dec 2022 20:42:07 +0100 Subject: [PATCH] Add nss-lookup to the systemd wants (#791) * Add nss-lookup to the systemd wants to ensure DNS is running before starting nebula * Add Ansible & example service scripts * Fix #797 * Align Ansible scripts and examples Co-authored-by: John Maguire --- dist/arch/nebula.service | 4 ++-- dist/fedora/nebula.service | 5 ++--- .../ansible/roles/nebula/files/systemd.nebula.service | 7 ++++--- examples/service_scripts/nebula.service | 6 +++--- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/dist/arch/nebula.service b/dist/arch/nebula.service index d8703c8..7e5335a 100644 --- a/dist/arch/nebula.service +++ b/dist/arch/nebula.service @@ -1,6 +1,6 @@ [Unit] -Description=nebula -Wants=basic.target network-online.target +Description=Nebula overlay networking tool +Wants=basic.target network-online.target nss-lookup.target time-sync.target After=basic.target network.target network-online.target [Service] diff --git a/dist/fedora/nebula.service b/dist/fedora/nebula.service index df4baf6..21a99c5 100644 --- a/dist/fedora/nebula.service +++ b/dist/fedora/nebula.service @@ -1,15 +1,14 @@ [Unit] Description=Nebula overlay networking tool - +Wants=basic.target network-online.target nss-lookup.target time-sync.target After=basic.target network.target network-online.target Before=sshd.service -Wants=basic.target network-online.target [Service] +SyslogIdentifier=nebula ExecReload=/bin/kill -HUP $MAINPID ExecStart=/usr/bin/nebula -config /etc/nebula/config.yml Restart=always -SyslogIdentifier=nebula [Install] WantedBy=multi-user.target diff --git a/examples/quickstart-vagrant/ansible/roles/nebula/files/systemd.nebula.service b/examples/quickstart-vagrant/ansible/roles/nebula/files/systemd.nebula.service index c22b4a7..fd7a067 100644 --- a/examples/quickstart-vagrant/ansible/roles/nebula/files/systemd.nebula.service +++ b/examples/quickstart-vagrant/ansible/roles/nebula/files/systemd.nebula.service @@ -1,7 +1,8 @@ [Unit] -Description=nebula -Wants=basic.target -After=basic.target network.target +Description=Nebula overlay networking tool +Wants=basic.target network-online.target nss-lookup.target time-sync.target +After=basic.target network.target network-online.target +Before=sshd.service [Service] SyslogIdentifier=nebula diff --git a/examples/service_scripts/nebula.service b/examples/service_scripts/nebula.service index 19f3900..fd7a067 100644 --- a/examples/service_scripts/nebula.service +++ b/examples/service_scripts/nebula.service @@ -1,7 +1,7 @@ [Unit] -Description=nebula -Wants=basic.target -After=basic.target network.target +Description=Nebula overlay networking tool +Wants=basic.target network-online.target nss-lookup.target time-sync.target +After=basic.target network.target network-online.target Before=sshd.service [Service]