我正在关注here的nginx教程,并按照教程中的说明在myproject.conf
中创建了/etc/init/
文件。代码如下:
description "uWSGI server instance configured to serve myproject"
start on runlevel [2345]
stop on runlevel [!2345]
setuid ec2-user
setgid www-data
env PATH=/home/ec2-user/login_test/venv/bin
chdir /home/ec2-user/login_test/oauth_login
exec uwsgi --ini wsgi.ini
当我尝试通过提供sudo start myproject
来激活它时,它会返回:
start: Unknown job: myproject
我怎样才能让它发挥作用?