Upstart helpers (abstract jobs and event aliases) for Oneiric

Marc - A. Dahlhaus mad at wol.de
Wed Jun 8 09:21:43 UTC 2011


Am Mittwoch, den 08.06.2011, 02:49 +0200 schrieb Jan Claeys:
> Marc - A. Dahlhaus schreef op di 07-06-2011 om 21:15 [+0200]:
> > As all "Common Services" should be mutually exclusive installed, so
> > each of them can use the same alias stanza value. 
> 
> It's often possible to install them in parallel, but choose one with the
> "alternatives" system for example...

Right, but alternatives has to handle the deactivation of the not used
"Common Service" alternatives in /etc/init also when changing the
alternative. We would have a race in handling the alternatives in the
upstart event-chain otherwise. Starting of a "Common Service" is
mutually exclusive.

Another possible way might be to just provide a meta package that trows
in a display-manager.conf that starts and stops on the events we want
any display-manager to run on and use its starting and stopping events
in the job-config e.g. gdm.conf (the way that scott explained in his
mail in this thread), we don't have to hardcode all display managers in
the display-manager.conf file if all display managers hook in on its
starting and stopping events. Even "initctl {start,stop,restart}
display-manager" works out nicely this way because the real job react on
the events in the way we expect. But "initctl reload display-manager"
doesn't work this way.

An alias stanza would be a way around the meta package for the majority
of "Common Services" and would respect the kiss principle if "initctl
{start,stop,restart,reload,status} $alias" would work on a job that has
the given alias configured.


Marc




More information about the upstart-devel mailing list