虽然没有得到官方支持,但我想在 Debian Jessie 上运行 Chef Server 12 (12.3.0)。
修复 Debian 的 systemd ego 故障后,如chef-cookbooks/chef-server#86,正在安装并成功运行。
但是,runit
设置似乎不正确:
# chef-server-ctl status
fail: bookshelf: unable to change to service directory: file does not exist
fail: nginx: unable to change to service directory: file does not exist
...
我还不是 systemd 和 runit 的专家,但这里有一些调试信息:
# systemctl status private_chef-runsvdir-start.service
● private_chef-runsvdir-start.service - private_chef Runit Process Supervisor
Loaded: loaded (/etc/systemd/system/private_chef-runsvdir-start.service; enabled)
Active: active (running) since Sun 2015-11-15 14:52:13 UTC; 36min ago
Main PID: 2572 (runsvdir)
CGroup: /system.slice/private_chef-runsvdir-start.service
├─2572 runsvdir -P /opt/opscode/service log: ....................................................................................................................................................................................
├─2702 runsv rabbitmq
├─2719 ....
检查命令的状态sv
:
# sv status bookshelf
fail: bookshelf: unable to change to service directory: file does not exist
# sv status /opt/opscode/service/bookshelf/
run: /opt/opscode/service/bookshelf/: (pid 6075) 2242s; run: log: (pid 6116) 2241s
我假设在某个时候sv
缺少runsvdir
( -P /opt/opscode/service
) 提供的路径参数。有什么方法可以将这个额外的目录添加到 的“搜索路径”中runit
吗?
编辑:导出$SVDIR
( export SVDIR=/opt/opscode/service
) 至少可以帮助我解决当前用户会话的问题。问题仍然是,sudo
无论导出到哪里,都会忽略此问题。