[systemd-devel] StandardOutput and StandardError permissions and ownership

Kamil Jońca kjonca at o2.pl
Fri Sep 21 21:26:52 UTC 2018


I have service unit with is run as user news and have redirected
standard output stderr.
ie.

--8<---------------cut here---------------start------------->8---
[Service]
User=news
Type=oneshot
StandardOutput=file:%T/use-newsx/%n.out
StandardError=file:%T/use-newsx/%n.err
....
--8<---------------cut here---------------end--------------->8---
But I standard output is owned by root. How can I make it owned by news?
This is template service, so I cannot use /etc/tmpfiles.d - I do not
know file names in advance.

KJ

-- 
http://wolnelektury.pl/wesprzyj/teraz/
Spokojnie... To tylko prowokacja.


More information about the systemd-devel mailing list