:: Re: [DNG] startup scripts (was dng@…
Top Pagina
Delete this message
Reply to this message
Auteur: Mat
Datum:  
Aan: dng
Onderwerp: Re: [DNG] startup scripts (was dng@lists.dyne.org)
On 18/07/15 12:42, Fred DC wrote:
> On 18/07/2015 10:49, Laurent Bercot wrote:
>> ....
>> Believe me, providing sysv-rc compatibility when you're working on
>> a supervision suite is no small feat: the paradigm is very different,
>> ....
>> ..... If it was easy, we would have provided compatibility packages
>> long ago, and supervision would already rule the world (with a gentle,
>> good hand).
>>
>
> I am not saying that runit is better as s6 - all I want to point out is
> that debian runit, until recently, intergrates fairly well with sysv-rc.
>
> Yes, the supervised services do need their own service-framework with
> their own scripts. For me (as a simple user) the hard nut to crack was
> to write stubs and a script which during a debian-update translate the
> inet-calls to sv-calls without insserv telling me to take a hike.


I solved this issue by diverting the original package's startup script
and replacing it with a symlink to /usr/bin/sv in the postinst's
scripts. As an example here is the postinst script of my nginx-run package:
http://parad0x.org/git/debian-run/nginx-run/tree/debian/postinst

I also patched insserv to recognise and ignore symlinks to /usr/bin/sv
to make this work nicely. The patch is here:
http://parad0x.org/git/debian-run/insserv/

Native support for alternative init systems would hopefully obsolete the
need for these kind of tweaks, but in the meantime they make for a very
smooth integration of runnit with debian.

I haven't tried s6 yet, but it's on my bucket list.

--
Mat <mat@???>