Gentoo Archives: gentoo-alt

From: Fabian Groffen <grobian@g.o>
To: gentoo-alt@l.g.o
Subject: Re: [gentoo-alt] init.d in prefix.
Date: Thu, 15 May 2008 08:29:45
In Reply to: [gentoo-alt] init.d in prefix. by Markus Duft
On 15-05-2008 10:12:01 +0200, Markus Duft wrote:
> Hi > > I just fixed the openssh server for interix (yeehaa), and for the > purpose of starting this whole thing without worrying about keys and > such, I would have really liked to use the init.d script to fire it > up. The init script still would require some eprefixification, but the > bigger problem is, that runscript is missing in baselayout-prefix... > Are there any thoughts in that direction?
Yeah, search bugzilla and the -dev list on gsoc prefix ideas.
> I can think of three scenarios on how services in prefix _could_ work: > > 1) all init.d scripts are run when entering the prefix, thus called by > some bashrc script. > 2) one single command is registered as a service in the host system > (called the "prefix-service" or so *lol*), which kicks on all > other init.d's from the prefix. > 3) each service has to be started manually by running the init script.
All three have been discussed on -dev I think.
> Any thoughts about this? What about openrc? I must admit, that I right > now have just a very shallow knowledge of all this... still I feel > that sooner or later we'll need _some_ facility to run init.d scripts > - even if it's manual only.
openrc is our only hope/option. The bastard baselayout we have right now is REALLY old (it dates back from the early dark ages of 3rd generation Prefix, when vikings were still hyjacking packages and machines...)
> A little background on why I'd need this (I could of course do what I > want without init scripts, but it would be more painfull): we have an > automated setup for new interix machines in our company. Since we use > prefix as the "real" system, and interix is just there to give us the > very basics while bootstrapping (and the libc), it would be really > cool to run sshd from prefix, instead of installing some binary > version with closed-source patches applied (urgh...)
You don't have to expect any straw laid on your road from me (that probably isn't English, but maybe you get the point ;) ), it is just that I don't have the time/interest/need for it. I do see a need for it. However, if you do start working on this, please be open about the process, discuss, and take some of the bugs on it into account. I personally feel that the last thing we want with a thing like that is to have a hacky "just works" solution. Roy (UberLord) Marples already added some stuff that we need in OpenRC. I would prefer a single point in the system where you can "switch on/off" the prefix init system. That is, like for OpenRC when the system boots or shuts down. This need not to be related to the physical boot/shutdown. I think it needs to be a one-liner (a script, or a command built into openrc, maybe just "prefix-init 3" or something similar) that each user can hook in such a way that he/she prefers. For me it would be sufficient to start the stuff after I booted my machine (every once in a long while usually), a sysadmin might want to make it a /etc/init.d/prefix-init script... Whatever. I think the number of tastes are unlimited here. So let us just deliver the "magic button" to start and stop the entire system (for the runlevel stuff, rc-update add default bla stuff), and of course for many users `${EPREFIX}/etc/init.d/postgresql start` will be enough, so they don't need any automatic starting at all :) -- Fabian Groffen Gentoo on a different level -- gentoo-alt@l.g.o mailing list