[Bug 247626] net/py-wsdd: Update to 0.6.1
bugzilla-noreply at freebsd.org
bugzilla-noreply at freebsd.org
Mon Jun 29 18:49:01 UTC 2020
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=247626
--- Comment #2 from Jeremy Chadwick <jdc at koitsu.org> ---
(In reply to Hiroo Ono from comment #1)
In general, this rc script provided by the vendor is pretty bad. Your
modification fixes a long-standing problem of the daemon not TRULY being
stopped properly, which is great!
The vendor version has an unnecesary dependency on Samba (testparm) just for
something like "set the workgroup name", and does not let you set your own
flags in rc.conf for wsdd (often needed for things like "-i em0"). That's a
feature I really, really needed.
What I use is below, named "wsdd_alternate" as to not conflict with the
port/pkg one. It allows me to do this in rc.conf:
wsdd_alternate_enable="yes"
wsdd_alternate_args="-w WORKGROUP -4 -i em0 -v -v -v"
Keep in mind I COULD NOT call the variable wsdd_alternate_flags because that
ends up adding the flags to daemon(8) as well (bad). I don't know how to
override that behaviour without writing a bunch of wsdd_alternate_prestart()
etc. nonsense.
#!/bin/sh
# PROVIDE: wsdd_alternate
# REQUIRE: DAEMON NETWORKING SERVERS
# BEFORE: LOGIN
# KEYWORD: shutdown
. /etc/rc.subr
name=wsdd_alternate
rcvar=wsdd_alternate_enable
load_rc_config $name
: ${wsdd_alternate_enable:="NO"}
: ${wsdd_alternate_args:=""}
pidfile="/var/run/${name}.pid"
procname="python3"
command="/usr/sbin/daemon"
command_args="-f -S -p ${pidfile} -u daemon -T wsdd /conf/ME/scripts/wsdd.py
${wsdd_alternate_args}"
run_rc_command "$1"
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the freebsd-ports-bugs
mailing list