Homec4science

Start phd daemons as the correctly configured user and refuse otherwise

Authored by Fabian Stelzer <fs@gigacodes.de> on Dec 23 2014, 17:11.

Description

Start phd daemons as the correctly configured user and refuse otherwise

Summary:
Fixes T5196
If no phd.user is configured the behaviour is unchanged besides printing a warning when run as root (Usually i would add an exit(1) here but that would break existing installs who do that).
If phd.user is set and the current user is root it will run the daemon as: su USER -c "command" (I'm not sure if this works for every platform needed)
Otherwise it will refuse to start if configured and current user mismatch.

Test Plan: Stopped & Started phd daemon with various users and different phd.user settings including root

Reviewers: #blessed_reviewers, epriestley

Reviewed By: #blessed_reviewers, epriestley

Subscribers: vinzent, epriestley

Maniphest Tasks: T5196

Differential Revision: https://secure.phabricator.com/D11036

Details

Committed
epriestley <git@epriestley.com>Dec 23 2014, 17:15
Pushed
aubortJan 31 2017, 17:16
Parents
rPH6132d8012b02: show the current size limit when a file upload fails
Branches
Unknown
Tags
Unknown

Event Timeline

epriestley <git@epriestley.com> committed rPH2fedb6f941d8: Start phd daemons as the correctly configured user and refuse otherwise (authored by Fabian Stelzer <fs@gigacodes.de>).Dec 23 2014, 17:15