From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8140 invoked by uid 1002); 6 May 2003 09:40:28 -0000 Mailing-List: contact gentoo-dev-help@gentoo.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@gentoo.org Received: (qmail 30314 invoked from network); 6 May 2003 09:40:28 -0000 X-Authentication-Warning: bru-cse-075.cisco.com: wmertens owned process doing -bs Date: Tue, 6 May 2003 11:40:26 +0200 (CEST) From: Wout Mertens X-X-Sender: wmertens@bru-cse-075.cisco.com To: Martin Schlemmer cc: Wolfram Schlich , Gentoo-Dev mailinglist In-Reply-To: <1052167146.4459.41.camel@nosferatu.lan> Message-ID: References: <20030505202336.ALLYOURBASEAREBELONGTOUS.I23529@bla.fasel.org> <1052167146.4459.41.camel@nosferatu.lan> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Subject: Re: [gentoo-dev] rc-scripts/init: new service dependency X-Archives-Salt: 2218384a-6e59-4cad-80a4-c8533024286d X-Archives-Hash: 1b4a39d3819b3c174bca35a890b916db On Mon, 5 May 2003, Martin Schlemmer wrote: > On Mon, 2003-05-05 at 22:23, Wolfram Schlich wrote: > > > What about a new dependency like "triggeredby"? > > Another name could be "stickto"... > > This would/should/could both affect "start" and "stop" operations. E.g.: > > > > /etc/init.d/ddclient: > > -> triggeredby net.ppp0 > > -> after net.ppp0 > > > > This would cause ddclient to be started when net.ppp0 is started, but > > due to the "after" dep, it would be started *after* net.ppp0. > > Kinda reverse/twisted need dependency... or something. > > > > This "triggeredby" could be applied to e.g. squid, iptables, postfix... all the > > stuff you *might* choose to need when connecting to the internet but > > don't want to start before you *really* connect. > > > > Might be a good feature to support. I just do not like the name =) How about subscribe? And you can ask to be called before and/or after the script you subscribe to: subscribe after net.ppp0 event() { case $2 in start|restart) start ;; stop) stop ;; esac } This would make runscript call ddclients event() after net.ppp0 was run, with $1 set to the script, $2 set to the action and $3 set to before or after. Of course, this still doesn't fix having multiple ways of bringing up your interface, like I proposed for gentoo-net (need to work on that :-/). My proposal also took care of calling ddclient after the interface was up... Wout. -- gentoo-dev@gentoo.org mailing list