Page MenuHomeFreeBSD

D15534.id44802.diff
No OneTemporary

D15534.id44802.diff

Index: head/net/zerotier/Makefile
===================================================================
--- head/net/zerotier/Makefile
+++ head/net/zerotier/Makefile
@@ -2,7 +2,7 @@
# $FreeBSD$
PORTNAME= zerotier
-DISTVERSION= 1.2.8
+DISTVERSION= 1.2.10
CATEGORIES= net
MAINTAINER= dch@FreeBSD.org
@@ -29,10 +29,21 @@
PLIST_FILES= bin/zerotier-cli bin/zerotier-idtool sbin/zerotier-one
+.include <bsd.port.pre.mk>
+
+.if ${OPSYS} == "FreeBSD"
+# log output via syslog when daemon(8) supports it
+.if ((${OSVERSION} >= 1100513 && ${OSVERSION} < 1200000) || ${OSVERSION} >= 1200015)
+SUB_LIST+= ZEROTIER_SYSLOG="-s debug -T zerotier"
+.else
+SUB_LIST+= ZEROTIER_SYSLOG=""
+.endif
+.endif
+
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/zerotier-one ${STAGEDIR}${PREFIX}/sbin/
.for l in zerotier-cli zerotier-idtool
- ${LN} -sf ../sbin/zerotier-one ${STAGEDIR}${PREFIX}/bin/${l}
+ ${RLN} ${STAGEDIR}${PREFIX}/sbin/zerotier-one ${STAGEDIR}${PREFIX}/bin/${l}
.endfor
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
Index: head/net/zerotier/distinfo
===================================================================
--- head/net/zerotier/distinfo
+++ head/net/zerotier/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1525679369
-SHA256 (zerotier-ZeroTierOne-1.2.8_GH0.tar.gz) = 08e2df34550d6bb68e106eaac48babb481160046818b0944ec41f1e158548a47
-SIZE (zerotier-ZeroTierOne-1.2.8_GH0.tar.gz) = 6009764
+TIMESTAMP = 1529964792
+SHA256 (zerotier-ZeroTierOne-1.2.10_GH0.tar.gz) = 1c79ec57e67764079a77704b336e642ae3cf221dc8088b0cf9e9c81e0a9c0c57
+SIZE (zerotier-ZeroTierOne-1.2.10_GH0.tar.gz) = 6056935
Index: head/net/zerotier/files/zerotier.in
===================================================================
--- head/net/zerotier/files/zerotier.in
+++ head/net/zerotier/files/zerotier.in
@@ -3,8 +3,8 @@
# $FreeBSD$
#
# PROVIDE: zerotier
-# REQUIRE: FILESYSTEMS netif
-# BEFORE: pf ipfw ipfilter
+# REQUIRE: FILESYSTEMS devfs
+# BEFORE: pf ipfw
# KEYWORD: shutdown
#
# Add these lines to /etc/rc.conf.local or /etc/rc.conf
@@ -22,8 +22,19 @@
: ${zerotier_enable:="NO"}
-command=%%PREFIX%%/sbin/${name}-one
+required_modules="if_tap"
-command_args="-d"
+pidfile="/var/run/${name}.pid"
+start_precmd="install -o root /dev/null ${pidfile}"
+command="/usr/sbin/daemon"
+command_args=" \
+ -c \
+ -t ${name} \
+ -r \
+ -P ${pidfile} \
+ %%ZEROTIER_SYSLOG%% \
+ /usr/local/sbin/${name}-one"
+
run_rc_command "$1"
+
Index: head/net/zerotier/pkg-message
===================================================================
--- head/net/zerotier/pkg-message
+++ head/net/zerotier/pkg-message
@@ -8,4 +8,13 @@
zerotier-cli join <network>
+If you are running other daemons or require firewall rules to depend on
+zerotier interfaces being available at startup, you may need to enable
+the following sysctl in /etc/sysctl.conf:
+
+net.link.tap.up_on_open=1
+
+This avoids a race condition where zerotier interfaces are created, but
+not up, prior to firewalls and services trying to use them.
+
#################################

File Metadata

Mime Type
text/plain
Expires
Mon, Feb 9, 6:13 AM (15 h, 46 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
28476398
Default Alt Text
D15534.id44802.diff (2 KB)

Event Timeline