Commit 2d240e58e073 ("teamd: add Before=network.target to systemd
service file") wants teamd to be stopped after network service is
stopped when system shutdown.
But 'Before=network-pre.target' doesn't actually work on that case.
'network-pre.target' is introduced in systemd to make it possible
to explicitly order things before networking is started (or stop
after networking has been stopped).
So this patch changes it to Before=network-pre.target.
Fixes: 2d240e58e073 ("teamd: add Before=network.target to systemd service
file")
Signed-off-by: Xin Long <lucien.xin(a)gmail.com>
---
teamd/redhat/systemd/teamd@.service | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/teamd/redhat/systemd/teamd@.service b/teamd/redhat/systemd/teamd@.service
index 3a39a26..3f9f638 100644
--- a/teamd/redhat/systemd/teamd@.service
+++ b/teamd/redhat/systemd/teamd@.service
@@ -1,6 +1,7 @@
[Unit]
Description=Team Daemon for device %I
-Before=network.target
+Before=network-pre.target
+Wants=network-pre.target
[Service]
BusName=org.libteam.teamd.%i
--
2.1.0