package/radvd: disable by default in systemd preset-all
authorCarlos Santos <unixmania@gmail.com>
Sat, 22 Feb 2020 14:47:06 +0000 (11:47 -0300)
committerYann E. MORIN <yann.morin.1998@free.fr>
Sat, 22 Feb 2020 18:11:40 +0000 (19:11 +0100)
We don't provide a configuration file, so disable radvd by default.

Update the help message with instructions on how to enable radvd at
build time with systemd.

Signed-off-by: Carlos Santos <unixmania@gmail.com>
Signed-off-by: Yann E. MORIN <yann.morin.1998@free.fr>
package/radvd/50-radvd.preset [new file with mode: 0644]
package/radvd/Config.in
package/radvd/radvd.mk

diff --git a/package/radvd/50-radvd.preset b/package/radvd/50-radvd.preset
new file mode 100644 (file)
index 0000000..90d0ee4
--- /dev/null
@@ -0,0 +1 @@
+disable radvd.service
index 48aeedc08f195ce96aba5a2b40f36067f551ff5d..fa5a20c4c1db2d1ab7f262ac49fa175aaf4807a5 100644 (file)
@@ -5,4 +5,12 @@ config BR2_PACKAGE_RADVD
        help
          IPv6 Router Advertisement Daemon.
 
+         On busybox and sysvinit systems, radvd will be started only if
+         a /etc/radvd.conf exists.
+
+         To enable it at build time with systemd, add /etc/radvd.conf
+         and a /etc/systemd/system-preset/40-radvd.preset file with
+
+           enable radvd.service
+
          http://www.litech.org/radvd/
index 5679e613d41b23f1c33a08ee89ca2dbd0f583e84..3358264f18f33ee4049f234683f246dd9020d2f8 100644 (file)
@@ -17,6 +17,12 @@ RADVD_AUTORECONF = YES
 RADVD_LICENSE = BSD-4-Clause-like
 RADVD_LICENSE_FILES = COPYRIGHT
 
+# We don't provide /etc/radvd.conf, so disable the service by default.
+define RADVD_INSTALL_INIT_SYSTEMD
+       $(INSTALL) -D -m 0644 package/radvd/50-radvd.preset \
+               $(TARGET_DIR)/usr/lib/systemd/system-preset/50-radvd.preset
+endef
+
 define RADVD_INSTALL_INIT_SYSV
        $(INSTALL) -D -m 0755 package/radvd/S50radvd $(TARGET_DIR)/etc/init.d/S50radvd
 endef