我目前正在嘗試在Raspberry Pi上安裝並運行Phabricator以供個人使用(即使它並非由Phacility推薦,我還是認爲我仍然試一試)。到目前爲止,我能夠設置除phd用戶之外的所有內容作爲守護進程。Phabricator Daemon:`phd`無法使用`sudo`切換到正確的用戶
/etc/passwd文件
phd:x:1001:1001:,,,:/home/phd:/bin/bash
/etc/shadow中
phd:NP:17107:0:99999:7:::
我創建的用戶博士學位,並在陰影給IM NP,但開始時還是讓Phabricator無法切換到博士守護進程。
sudo ./bin/phd restart
Interrupting process 19517...
Process 19517 exited.
Freeing active task leases...
Freed 0 task lease(s).
Starting daemons as phd
Launching daemons:
(Logs will appear in "/var/tmp/phd/log/daemons.log".)
PhabricatorRepositoryPullLocalDaemon (Static)
PhabricatorTriggerDaemon (Static)
PhabricatorTaskmasterDaemon (Autoscaling: group=task, pool=4, reserve=0)
Usage Exception: Daemons are configured to run as user "phd" in
configuration option `phd.user`, but the current user is "root" and
`phd` was unable to switch to the correct user with `sudo`. Command output:
Command failed with error #255!
COMMAND
exec sudo -En -u 'phd' -- ./phd-daemon '--verbose'
STDOUT
(empty)
STDERR
[2016-11-04 08:54:54] EXCEPTION: (Exception) Specified daemon PID directory
('/var/tmp/phd/pid') does not exist or is not writable by the daemon user!
at [<phutil>/src/daemon/PhutilDaemonOverseer.php:115]
arcanist(head=master, ref.master=fad85844314b), phabricator(head=master,
ref.master=6982bded7124), phutil(head=master, ref.master=2b7b1007bf87)
#0 PhutilDaemonOverseer::__construct(array) called at
[<phabricator>/scripts/daemon/launch_daemon.php:13]
我試過的是通過su phd -c "/home/phd/phabricator/bin/phd restart"
啓動phd用戶,但是從我那裏查詢密碼。
我捱得很近,本指南https://secure.phabricator.com/book/phabricator/article/diffusion_hosting/以及本https://gist.github.com/sparrc/b4eff48a3e7af8411fc1
任何幫助,真的,真的很感謝!
也許仔細看一下STDERR抱怨的PID目錄的權限。 – JSON
男人,非常感謝你......你不能相信它是多麼的非常活躍。 如果任何人會絆倒accros這一點,解決辦法是: 須藤搭配chmod 775/var/tmp中/博士/ PID sudo的文件模式去+ W/var/tmp中/博士/ PID – SSND