chiark / gitweb /
tmpfiles: make "f" lines behaviour match what the documentation says
authorLennart Poettering <lennart@poettering.net>
Wed, 24 Jan 2018 09:54:10 +0000 (10:54 +0100)
committerSven Eden <yamakuzure@gmx.net>
Wed, 30 May 2018 05:50:18 +0000 (07:50 +0200)
commitcb4601c6ddf17f582987475efa8a162bf31c331d
tree199eb58a33050965f72bdcb00a7b77a330579a91
parent12884f51343ce73cc8d05a866c597527eaac1308
tmpfiles: make "f" lines behaviour match what the documentation says

CHANGE OF BEHAVIOUR — with this commit "f" line's behaviour is altered
to match what the documentation says: if an "argument" string is
specified it is written to the file only when the file didn't exist
before. Previously, it would be appended to the file each time
systemd-tmpfiles was invoked — which is not a particularly useful
behaviour as the tool is not idempotent then and the indicated files
grow without bounds each time the tool is invoked.

I did some spelunking whether this change in behaviour would break
things, but afaics nothing relies on the previous O_APPEND behaviour of
this line type, hence I think it's relatively safe to make "f" lines
work the way the docs say, rather than adding a new modifier for it or
so.

Triggered by:

https://lists.freedesktop.org/archives/systemd-devel/2018-January/040171.html
NEWS