不能以非root用户身份运行超级用户

时间:2019-10-14 20:10:33

标签: python debian root supervisord

我必须以非root用户身份运行超级用户。 我正在尝试在supervisord.conf的supervisor部分中设置用户,但是由于服务状态为“正在激活”并且什么也没有发生,因此无法重新启动supervisor。

Supervisord.conf:

[supervisord]
user=dev

重新启动服务:

me@server:/etc/supervisor$ sudo service supervisor status
● supervisor.service - Supervisor process control system for UNIX
   Loaded: loaded (/lib/systemd/system/supervisor.service; enabled; vendo
   Active: activating (auto-restart) (Result: exit-code) since Mon 2019-1
     Docs: http://supervisord.org
  Process: 11310 ExecStart=/usr/bin/supervisord -n -c /etc/supervisor/sup
 Main PID: 11310 (code=exited, status=2)

日志:

me@server:/etc/supervisor$ sudo cat /var/log/supervisor/supervisord.log
    2019-10-14 21:53:53,373 CRIT Supervisor is running as root.  Privileges were not dropped because no user is specified in the config file.  If you intend to run as root, you can set user=root in the config file to avoid this message.
    2019-10-14 21:53:53,375 WARN No file matches via include "/etc/supervisor/conf.d/*.conf"
    2019-10-14 21:53:53,383 CRIT Server 'inet_http_server' running without any HTTP authentication checking
    2019-10-14 21:53:53,384 CRIT Server 'unix_http_server' running without any HTTP authentication checking

我不确定该怎么做。我收到此消息“ Supervisor以root身份运行。由于未在配置文件中指定用户,因此没有删除特权。如果要以root身份运行,则可以在配置文件中设置user = root以避免出现此消息。”

我了解,如果我想以非root用户身份运行超级用户,则应按前面所述设置参数:“ user = dev ”。

我在SO上找到了一些类似的问题,但是我的问题没有答案。

0 个答案:

没有答案
相关问题