From e9a85e651191aa9152c46ad5b7b75c4b38e77394 Mon Sep 17 00:00:00 2001 From: Jouke Witteveen Date: Wed, 11 Apr 2012 18:28:22 +0200 Subject: Systemd service files The netcfg service provides support for the NETWORKS array in /etc/conf.d/netcfg through netcfg-daemon. The netcfg@ service allows individual profiles to be treated as services. These services wait until a connection is established (the other service has support for backgrounding)! --- systemd/netcfg.service | 13 +++++++++++++ systemd/netcfg@.service | 12 ++++++++++++ 2 files changed, 25 insertions(+) create mode 100644 systemd/netcfg.service create mode 100644 systemd/netcfg@.service (limited to 'systemd') diff --git a/systemd/netcfg.service b/systemd/netcfg.service new file mode 100644 index 0000000..d61d902 --- /dev/null +++ b/systemd/netcfg.service @@ -0,0 +1,13 @@ +[Unit] +Description=Netcfg multi-profile daemon +Before=network.target + +[Service] +Type=oneshot +RemainAfterExit=yes +EnvironmentFile=/etc/conf.d/netcfg +ExecStart=/usr/bin/netcfg-daemon start +ExecStop=/usr/bin/netcfg-daemon stop + +[Install] +WantedBy=multi-user.target diff --git a/systemd/netcfg@.service b/systemd/netcfg@.service new file mode 100644 index 0000000..5c0619d --- /dev/null +++ b/systemd/netcfg@.service @@ -0,0 +1,12 @@ +[Unit] +Description=Netcfg profile based networking service +Before=network.target + +[Service] +Type=oneshot +RemainAfterExit=yes +ExecStart=/usr/bin/netcfg check-iface %i +ExecStop=-/usr/bin/netcfg down %i + +[Install] +WantedBy=multi-user.target -- cgit v1.2.3-24-g4f1b