summaryrefslogtreecommitdiffstats
path: root/files/lldpd.in
diff options
context:
space:
mode:
Diffstat (limited to 'files/lldpd.in')
-rw-r--r--files/lldpd.in27
1 files changed, 27 insertions, 0 deletions
diff --git a/files/lldpd.in b/files/lldpd.in
new file mode 100644
index 0000000..2afe88c
--- /dev/null
+++ b/files/lldpd.in
@@ -0,0 +1,27 @@
+#!/bin/sh
+
+# $FreeBSD$
+#
+# PROVIDE: lldpd
+# REQUIRE: LOGIN
+# KEYWORD: shutdown
+#
+# Add the following lines to /etc/rc.conf to enable lldpd:
+# lldpd_enable (bool): Set to "NO" by default.
+# Set it to "YES" to enable lldpd.
+# lldpd_flags (str): Empty by default.
+#
+
+. /etc/rc.subr
+
+name=lldpd
+rcvar=lldpd_enable
+
+load_rc_config $name
+
+: ${lldpd_enable:="NO"}
+
+command=%%PREFIX%%/sbin/${name}
+pidfile=/var/run/${name}.pid
+
+run_rc_command "$1"