>>> Lennart Poettering <lenn...@poettering.net> schrieb am 15.05.2019 um 12:03 in Nachricht <20190515100311.GA22945@gardel-login>: > On Mi, 15.05.19 11:57, Ulrich Windl (ulrich.wi...@rz.uni‑regensburg.de) wrote: > >> >> could call "systemctl add‑wants ‑‑transient" to do the job, >> >> but at that point, that's more pedantic than practical. If you write a >> >> generator, your systemd‑fu should be high enough to know and >> >> understand systemd's symlink mechanisms... >> > >> > Precisely. if you write your own generator, then you need to know what >> > you do, and need to know how to place your symlinks. You are >> > essentially writing your own unit file installer that way and are >> > expected to create your own symlinks then. >> >> I didn't see it that way: Generated units are just as units installed by > some >> package manager, but specific to the local configuration. So why to make >> differences?: A unit is a file that is found by systemd (after the > generators >> finished)... > > Nope, that's simply not how they are designed. They are a mechanism > how to extend the systemd dependency tree and install additional > nodes in that tree. > > If you are looking for a generic converter of foreign stuff into > classic, persistent systemd unit files, then generators is not what > you should be using. Generators are life‑cycle bound to systemd > release cycles, and their output ceases to exist on every reload > boundary, and when the system is offline. If we'd allow generated > units to be installed that clear life‑cycle would be very much > blurred, as suddenly you'd have configuration that hooks them into the > system that is more persistant than the actual definitions of the > units themselves, and that's just borked... > > I mean, if you want to persistently enable a unit that is converted > from something else, then please write your own converted, and write > something to /etc/systemd/system, there's no need whatsoever to bother > systemd itself with that, you shouldn't use generators for that.
Sorry, I still don't get it: The only(?) difference is the path where they (units files) are found, and that the /run directory is volatile. Aren't the other differences not just "artificial"? > > Lennart > > ‑‑ > Lennart Poettering, Berlin _______________________________________________ systemd-devel mailing list firstname.lastname@example.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel