Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 7 Jun 2005 15:11:09 -0400
From:      "J.R. Oldroyd" <fbsd@opal.com>
To:        Brooks Davis <brooks@one-eyed-alien.net>
Cc:        freebsd-rc@freebsd.org
Subject:   Re: Use of rcorder for local rc.d/*.sh scripts
Message-ID:  <20050607191109.GU37208@linwhf.opal.com>
In-Reply-To: <20050607173741.GI11758@odin.ac.hmc.edu>
References:  <20050603143803.GP886@linwhf.opal.com> <42A4CA37.1050201@FreeBSD.org> <20050606235426.GA10526@odin.ac.hmc.edu> <20050607001447.GG37208@linwhf.opal.com> <20050607003142.GD10526@odin.ac.hmc.edu> <20050607033536.GH37208@linwhf.opal.com> <20050607160855.GO37208@linwhf.opal.com> <20050607173741.GI11758@odin.ac.hmc.edu>

next in thread | previous in thread | raw e-mail | index | archive | help

--veXX9dWIonWZEC6h
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Jun 07, 10:37, Brooks Davis wrote:
> >                          So, if this approach were adopted, several
> > changes will be needed to all local rc scripts:
> > 	- any with a .sh suffix will need to be renamed from
> > 	  "foo.sh" to "foo"
> > 	- any files like "*.sh.sample" will have to be moved
> > 	  elsewhere, or made non-executable
> > 	- rcorder tags will need to be added to any that care
> > 	  about the order of their execution, and names like
> > 	  "000.*" can be eliminated
>=20
> There is very little chance of getting this to fly.  Remember, any
> solution has to work for all releases currently supported by ports.  In
> practice, this currently means the security branches so anything that
> breaks existing localpkg based systems is not going to work.  I think
> that keeping the .sh extension is going to be required for the
> foreseeable future.  Requiring that rcorder runs on all the .sh files
> generate an appropriate order is probably a reasonable goal for 6.0.
> If we did that in 6.0, we could require the removal of non .sh files for
> 7.0 and remove the .sh extensions through a release dependent action in
> the RC_SUBR support in bsd.port.mk.  In theory you could do the RC_SUBR
> changes for 6.0, but big changes to requirements for ports are very time
> consuming, especially if you are going to modify bsd.port.mk.
>=20
> Any change of this order is going to require discussion on ports, and
> buy-in from portmgr.
>=20

Is this as bad as you're suggesting?

Agreed, requiring "foo.sh" be renamed to "foo" for so many ports
is a biggie, so perhaps we keep the *.sh for now, and arrange that
files in the local scripts dirs are run in a subshell from rc.subr,
rather than being sourced.  This is probably important for security
reasons, anyway.  It also keeps existing semantics, so should work
on all systems.

It also eliminates the issue with foo.sh.sample as such files
will continue to be ignored.

We only need to add rcorder tags on ports which currently use
"NNN.foo.sh" scripts, and we could even delay this by introducing
an extra rc.conf flag to have /etc/rc execute any local NNN files
immediately after SERVERS or such suitable point.

If you feel this is not the desired direction, let's revert back
to the "localpkg hack".  My goal here was to simply introduce the
use of rcorder for local scripts so that those scripts which do
have tags can take advantage of them and thereby fix a problem
in which some things currently don't start.

	-jr

--veXX9dWIonWZEC6h
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (FreeBSD)

iQDVAwUBQqXxTUkkqUax7f6FAQLH0gYAnwsFo3YgGxXfg6Y/lvkqDZifz0lscp5Q
UNGDDCVw0SzpnPW9kcJwzjW55VPn1RTKSB23AQ0+vehk8ZhxgksyPzGPSscuP0fD
yZjBTMihjJ7QutVprGmaqrNpW8wVPcyjmCzsN94qjVZqSRZT0/A9KlkvPugv9EnJ
nmi73HkXsNp9Fbi5MLyKLBWIFnkxYRlgXuIpDZ/Bs48yFFzRHMW5En2DiTw6sUlu
KAFHW0vWpYYVXjk+2dyYz8IVimbFHttO
=UfOE
-----END PGP SIGNATURE-----

--veXX9dWIonWZEC6h--




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