-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
systemd unit: run as 'daemon' user, not root #6
base: master
Are you sure you want to change the base?
Conversation
Debian has been running uptimed as 'daemon' for three years now. Root permissions are unneccessary. Packagers should ensure that /var/spool/uptimed is chown'ed on upgrade.
hmm, interesting! ...is there any document explaining the policy? (why the daemon user? why not nobody or something like that?) i can't seem to find anything like this for arch linux (the distro i currently use). |
Debians policy is at: https://wiki.debian.org/SystemGroups: uptimed needs to own history in /var/spool/uptimed, so it's incompatible with Debian's "nobody". I think creating dedicated user for uptimed would be an overkill. Arch mainly follows upstream, so if upstream uptimed runs as root, the same is true for Arch. I was unable to find any specific policy. Fedora did not seem to have policy about "daemon" user, too. I've switched uptimed from running as root to running as daemon in Fedora 23, though. |
If i had to made the switch to a non-root user, I'd create a new user (_uptimed) instead of using daemon but that boat sailed long ago for Debian, so yeah pls accept this PR |
hmm, has this advanced/changed in debian/fedora meanwhile? also, if ownership of /var/spool/uptimed is to be changed, shouldn't there a systemd-tmpfiles snippet as well? |
Current state:
|
Hi, sorry for chiming in late. Did seem to have overseen the according notification and stumbled over the nick highlight just by accident. @rpodgorny wrote:
@zdzichu wrote:
I can confirm that there were no changes wrt. the user uptimed is running under on Debian since I took over the uptimed Debian package. And I also don't intend to change this as it works well that way. @rpodgorny wrote:
No. The ownership of that directory is set in Debian's |
I think it is warranted to merge this PR now. |
Debian has been running uptimed as 'daemon' for three years now.
Root permissions are unneccessary. Packagers should ensure that
/var/spool/uptimed is chown'ed on upgrade.