[Fixed]-Uwsgi: unrecognized option '–module=MyProject.wsgi:application'


I ran into this recently when I tried to use the version of uWSGI in the Unbuntu 12.04 repo (1.0.3). It looks likes that version is a bit old. Just use pip to grab it (1.2.5).

pip install uwsgi


You probably need to add the --plugins option to your command line to use the system installed uwsgi. On Fedora 17, at least, this is neccesary for me:

$ uwsgi --http --module=wsgiref.simple_server:demo_app
uwsgi: unrecognized option '--module=wsgiref.simple_server:demo_app'
getopt_long() error

but this works:

$ uwsgi --http --plugins python --module=wsgiref.simple_server:demo_app
*** Starting uWSGI 1.2.4 (64bit) on [Thu Aug 30 14:09:57 2012] ***
[.. snip]


Try this

uwsgi --socket /run/uwsgi/mysite.sock --chdir /home/ubuntu/mysite/ --plugin The_OJ.wsgi --chmod-socket=666

Leave a comment