On Thu, 2011-05-26 at 10:43 +0200, Michael Biebl wrote: > 2011/5/26 Vasiliy G Tolstov <[email protected]>: > > Hello. If i want to write daemon, that can be running by regular init > > system (openrc, upstart and others) and systemd, how can i check inside > > my daemon, that it runs from systemd? > > In compile phase, i can build with systemd support and install service > > file, but if i do not want to write and build separate binaries for two > > init daemons, how can i solve this? > > Why would you need separate binaries? > Do you want your daemon to support socket based activation? > > Michael >
Yes and much more. In documentation in systemd (man sd-daemon) says that new style daemons can use systemd funcationality, in compile time i can add some specific code to my progect to use systemd mechanism: notify, dbus notify and others.. But how can i determine in run time - what init system runs me ? -- Vasiliy G Tolstov <[email protected]> Selfip.Ru _______________________________________________ systemd-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/systemd-devel
