[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: RFC: initscript policy proposal



On Thu, Nov 02, 2000 at 09:57:43AM -0200, Henrique M Holschuh wrote:
> file-rc is sysv-like. I mean something much more exotic, such as an
> initscript subsystem capable of dynamically fetching the init script from
> somewhere else. invoke-rc.d allows that sort of stuff to be implemented if
> invoke-rc.d is the only allowed way to call initscripts.

*shrug* We don't have anything like that, so it's not realy relevant.

> > I don't really think it's a good idea to call maybe-restart for scripts
> > that don't implement it.
> The initscript should just output an error if it is given an unsupported
> action; if it does anything else, that's a bug.

Well, yes, but we shouldn't have random errors occuring all the time in
normal use.

> > Perhaps it'd be better to have
> > 	invoke-rc.d foo maybe-restart
> > be the way of calling /e/i/foo maybe-restart so it won't get invoked
> > when it's not supported?
> I don't follow you. You can invoke-rc.d foo maybe-restart to call
> maybe-restart directly, yes. It is the way to ask for a maybe-restart, yes.
> What has that to do with using maybe-restart as the fallback action for
> restart out-of-runlevel ?

ie, not having any "fallback" options, just always translating invoke-rc.d
foo blah to /etc/init.d/foo blah or a no-op, depending on runlevel.

That way running a postinst works cleanly whatever runlevel you're in,
and whether you've implemented "maybe-restart" yet or not, and so on.

Cheers,
aj

-- 
Anthony Towns <aj@humbug.org.au> <http://azure.humbug.org.au/~aj/>
I don't speak for anyone save myself. GPG signed mail preferred.

  ``We reject: kings, presidents, and voting.
                 We believe in: rough consensus and working code.''
                                      -- Dave Clark

Attachment: pgp35eXYkosVG.pgp
Description: PGP signature


Reply to: