summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDimitri John Ledkov <xnox@ubuntu.com>2017-12-11 18:27:49 +0000
committerLennart Poettering <lennart@poettering.net>2018-01-11 12:40:44 +0100
commit1f1580139ed48dd308a6a2470baf037ae1ed6aab (patch)
tree4068590c02d72472f49823204a46ee77565ebcfd
parent27c1decf3172d11bef02629307c47e3124ba8927 (diff)
downloadsystemd-1f1580139ed48dd308a6a2470baf037ae1ed6aab.tar.gz
resolved.service: set DefaultDependencies=no
On systems that only use resolved for name resolution, there are usecases that require resolved to be started before sysinit target, such that network name resolution is available before network-online/sysinit targets. For example, cloud-init for some datasources hooks into the boot process ahead of sysinit target and may need network name resolution at that point already. systemd-resolved already starts pretty early in the process, thus starting it slightly earlier should not have negative side effects. However, this depends on resolved ability to connect to system DBus once that is up.
-rw-r--r--units/systemd-resolved.service.in6
1 files changed, 4 insertions, 2 deletions
diff --git a/units/systemd-resolved.service.in b/units/systemd-resolved.service.in
index 8059aa7b62..c4c7f1feef 100644
--- a/units/systemd-resolved.service.in
+++ b/units/systemd-resolved.service.in
@@ -13,8 +13,10 @@ Documentation=man:systemd-resolved.service(8)
Documentation=https://www.freedesktop.org/wiki/Software/systemd/resolved
Documentation=https://www.freedesktop.org/wiki/Software/systemd/writing-network-configuration-managers
Documentation=https://www.freedesktop.org/wiki/Software/systemd/writing-resolver-clients
-After=systemd-networkd.service network.target
-Before=network-online.target nss-lookup.target
+DefaultDependencies=no
+After=systemd-sysusers.service systemd-networkd.service
+Before=network.target nss-lookup.target shutdown.target
+Conflicts=shutdown.target
Wants=nss-lookup.target
[Service]