Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 10 Feb 2016 18:32:19 -0500
From:      "Chad J. Milios" <milios@ccsys.com>
To:        Garrett Wollman <wollman@bimajority.org>
Cc:        freebsd-rc@freebsd.org
Subject:   Re: Good example for startup script with multiple "profiles"?
Message-ID:  <da32e4fc2dff8c894027c713d8907993@cargobay.net>
In-Reply-To: <22203.48400.34474.502294@hergotha.csail.mit.edu>
References:  <22203.48400.34474.502294@hergotha.csail.mit.edu>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2016-02-10 17:43, Garrett Wollman wrote:
> It's sometimes useful to have a single rc script start multiple copies
> of the same service, using different options.  (For example, and my
> use case here, running a monitoring daemon with different parameters
> on "inside" and "outside" network interfaces.)  Is there a good
> example I can crib from for how best to code this up while taking
> maximal advantage of the rc.subr framework?
> 
> -GAWollman
> _______________________________________________
> freebsd-rc@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-rc
> To unsubscribe, send any mail to "freebsd-rc-unsubscribe@freebsd.org"

Not saying this is the absolute best approach, but take a look at 
security/openvpn. that is after what i modeled my enhancement to the 
dns/knot2 startup script in 
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=203931 . i think the 
diff in that PR would make a good example of what youre looking to 
accomplish, clearly illustrating the actual modification. knot2 is 
rather simple software so nothing's in the way to obscure the 
illustrative value youre looking for, yet it also has the extra control 
function in there referencing the knotc control utility executable



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?da32e4fc2dff8c894027c713d8907993>