tinc initialization (in both Red Hat and Debian families)

Julian Bäume julian at svg4all.de
Thu Sep 24 18:14:30 CEST 2015


Hi!

> Guus Sliepen <guus at tinc-vpn.org> hat am 24. September 2015 um 17:45
> geschrieben:
> 
> On Thu, Sep 24, 2015 at 05:51:30PM +0300, Răzvan Sandu wrote:
> 
> > Taking into account that both Red Hat and Debian (8.x) families now use
> > systemd, there is, IMHO, one small. but important correction to be done:
> > tinc's initialization.
> > 
> > IMHO, we need:
> > 
> > 1. A proper tinc.service file, included by default (prepackaged) in the
> > stock .deb and .rpm packages in Fedora, Debian, Ubuntu, CentOS, etc.
> > 
> > By "proper" I mean it will start tinc at the correct time during system's
> > initialization, have proper permissions, etc.
> 
> I agree. I would like it to follow systemd's way of doing things as much
> of possible. For example, in order to support multiple tinc daemons
> running, I'd like to use unit instances, so one can say:
> 
> systemctl start tinc at NETNAME.service
> 
> Where NETNAME is passed to tincd using the -n option of course. So that
> means no more nets.boot. Anyone having any ideas about this?

+1 something like that would be nice to have.

> > 2. On Red Hat systems, an /etc/sysconfig/tinc file, as a standard place to
> > pass initialization parameters to the tincd daemon. For example, the
> > network name (-n) to be used.
> > 
> > A similar configuration file should exist in Debian, but I'm less familiar
> > with the Debian initialization scheme.
> 
> I'm not too fond of supporting distribution specific stuff in tinc
> upstream. As mentioned above, the netname issue can be handled by
> systemd using instances. As for other parameters, I know it is possible
> to specify a file with the format VARIABLE=VALUE and have it read by
> systemd, so you can use those variables in the unit files. It works with
> Debian's /etc/default/tinc more or less. I don't know about Red Hat's
> sysconfig files. Or I might add some extra configuration options to tinc
> for those command line switches that do not have a configuration file
> equivalent.

Indeed. In the end, packagers will have to manually do something about those
files anyway. So it's one thing to provide a base implementation of a unit file
upstream and ship it with tinc source. Or even just put a reference file into
the wiki. Finally leave such distribution specific details to the package
maintainer of the distribution. That's what they are good at.

I created a package for openSUSE and the init script, I added, was the (IMHO)
best of all the init scripts I found out there + some extras. I borrowed from
gentoo, debian and arch, IIRC. Unfortunately I didn't have the time to dive into
systemd, yet. So I don't have systemd support ready, at the moment.

Just my 2ct
Julian


More information about the tinc mailing list