启动gunicorn.service失败:单位gunicorn.service被屏蔽

问题描述

我正在尝试在 alibabacloud 上部署 django web 应用程序,一切似乎都运行良好(在虚拟环境中运行 gunicorn --bind 0.0.0.0:8000 project_name.wsgi)

然后在停用虚拟环境并进行设置后

[Unit]
Description=gunicorn daemon
After=network.target

[Service]
User=admin
Group=www-data
WorkingDirectory=/home/admin/project_name
ExecStart=/home/admin/project_name/myprojectenv/bin/gunicorn --access-logfile - --workers 3 --bind 
unix:/home/admin/project_name/project_name.sock project_name.wsgi:application

/etc/systemd/system/gunicorn.service 然后运行 ​​sudo systemctl start gunicorn 我不断收到错误

Failed to start gunicorn.service: Unit gunicorn.service is masked.

请问我该如何解决这个问题?

我尝试过 systemctl unmask gunicorn.socket 但它一直向我显示错误

Unit gunicorn.socket does not exist,proceeding anyway.
Failed to unmask unit: The name org.freedesktop.PolicyKit1 was not provided 
by any .service files

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)

相关问答

错误1:Request method ‘DELETE‘ not supported 错误还原:...
错误1:启动docker镜像时报错:Error response from daemon:...
错误1:private field ‘xxx‘ is never assigned 按Alt...
报错如下,通过源不能下载,最后警告pip需升级版本 Requirem...