On Wed, 20.07.11 16:21, Frank Murphy (frankly3d@xxxxxxxxx) wrote: > > On 20/07/11 14:53, Michal Schmidt wrote: > > On 07/20/2011 03:49 PM, Kostas Georgiou wrote: > >> This way the copied unit file never gets updated if the original one is > >> updated, with the old sysv scripts you could do an ln -s foo newfoo > >> and get the updates. > > > > You can use: > > .include /the/original/unit/file > > and only override the specific options you need. > > > > Michal > > Where would you place this line? > asked out of ignorance om my part. You have two options: a) if you want to make sure an upgrade doesn't muck with your changed unit file, just copy the file from /lib/systemd/system/foobar.service to /etc/sytemd/system/foobar.service and edit it there. b) If you have a unit file /lib/systemd/system/foobar.service where you would like to make some minimal changes but have the rest of the settings updated via at RPM upgrades, then create a new unit file in /etc/systemd/system/foobar.service, place ".include /lib/systemd/system/foobar.service" as first line in it and then all settings you want to override. Note that a small number of settings are additive though, and won't override previous settings. For example ReadOnlyDirectories= will always add an additional read-only dir, not override it was was set before. But those are very few, and in most cases it should be intuitive which ones those are (i.e. all those where it makes sense to appear multiple times). Lennart -- Lennart Poettering - Red Hat, Inc. -- devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxxx https://admin.fedoraproject.org/mailman/listinfo/devel