Should etc/rc.d/ike move to ports?
Doug Barton
dougb at FreeBSD.org
Fri Dec 16 16:45:29 PST 2005
Simon L. Nielsen wrote:
> On 2005.12.16 14:13:34 -0800, Doug Barton wrote:
>
>> Because it was previously not possible to run scripts for ports in the base
>> rcorder, and because the rc.d/ike script needed to run well before
>> localpkg, it was imported into the base, and lives currently in /etc/rc.d.
>> However, now that I am about to MFC the code that runs ports scripts in the
>> base rcorder, I'm wondering if we shouldn't add the rc.d script to the
>> port, and remove it from HEAD and RELENG_6 after my MFC. I would of course
>> be glad to assist with any details related to the move.
>
> Hey,
>
> Sound like a good idea. I actually hadn't noticed that the ike script
> had been updated to point at isakmpd, last I checked it looked like
> the ike script was just a leftover from the NetBSD import.
Interesting! In that case, I lean much more strongly toward removing it,
possible even in RELENG_5.
> I also thought I had committed the isakmpd rc.d script that I did for
> $REALJOB a while ago (based on the rc.d/ike script) to the port, but
> it looks like I forgot to do that.
Ok, sounds like you're on top of this then. The preferred way to do this
currently would be to add the script to the files directory, and the
following to the port Makefile:
USE_RC_SUBR= ike.sh
There is already some cool stuff in the ports infrastructure to handle these
scripts. Take a look at databases/mysql323-server if you want an example.
The current infrastructure already handles things like subbing out PREFIX,
etc. for you. In the near future the ports infrastructure will be updated to
then install that file as just ike on systems that are past the MFC date of
the local_startup changes, and as ike.sh on older systems so it will still
work.
> I will try to get the port updated to include an rc.d script this
> weekend, but no guarantees that I will get to it - Christmas is coming
> way to fast with all the required shopping ;-).
*sigh* tell me about it. There is no particular hurry to this, but if you
would please drop me a note when you make this update (just in case I miss
it) I would appreciate it. Ideally, if we delete the script from /etc/rc.d
(which is how I'm leaning), then I'd like to have time to do that so that it
can be MFC'ed before the RELENG_[56] freezes in 6 weeks.
> With regard to the magic keywords (mainly REQUIRE/BEFORE) I assume
> the ones currently in src/etc/rc.d/ike should be OK?
Well, if you use the ones that are there now, it will at least be no worse
than it is now. :) I don't know enough about this to be sure exactly what
the right thing to do is in regards to ordering. As for the other magic
words, you have to have PROVIDE in there, or rc.d won't recognize it, and if
this script isn't eligible for running in a jail, then the 'nojail' KEYWORD
should stay as well.
hth,
Doug
--
This .signature sanitized for your protection
More information about the freebsd-rc
mailing list