On Wed, May 10, 2017 at 08:36:29AM +0200, Bernhard Schmidt wrote: > On Mon, May 08, 2017 at 10:11:45PM +0200, Andreas Henriksson wrote: > > Hi, > > > I think it's much better to implement this logic natively in the daemon, > > so please see attached patch. Please note that it's gotten basically no > > testing at all, so review carefully. > > I really have to admit that patching the upstream source to search in > some Debian specific runtime directory is not making me particularly > happy. This needs documentation and forward-porting etc. > > Why not just make a little wrapper shell script that parses > /etc/default/ntp and does the cfg selection dance, then exec() ntp? This > would get all systemd features in a way easy to understand while > maintaining backward compatibility. Other than a "needless" invocation > of /bin/sh (which is an argument I'm still not buying) I see no > downsides. > > Kurt, what do you think?
I guess systemd is happy with an exec(), that it stays the same PID? In that case I would prefer that we do it with a script, which should be able to do the other things like adding the correct user to run as. Kurt