Has anyone tried using uWSGI with Cherokee? Can you share your experiences and what documents you relied upon the most? I am trying to get started from the documentation on both (uWSGI and Cherokee) websites. Nothing works yet. I am using Ubuntu 10.04.
Edit: To clarify, Cherokee has been working fine. I am getting the error message:
uWSGI Error, wsgi application not found
So something must be wrong with my configurations. Or maybe my application.
Yep, I just recently set this up in Ubuntu Lucid for a Pylons app.
First, I grabbed the latest cherokee from the team PPA.
https://launchpad.net/~cherokee-webserver/+archive/ppa
Next I installed the uwsgi latest into my virtualenv my app lives in via Pip which the uwsgi docs walk you through.
http://projects.unbit.it/uwsgi/wiki/Install
My app was already deployed via mod_wsgi so I was looking to reuse my .wsgi file. I ran into an issue getting the syntax for the uwsgi call right so I got some great help on their mailing list:
http://lists.unbit.it/pipermail/uwsgi/2010-June/000347.html
So I went through the docs in the cherokee cookbook and replaced the uwsgi line with a tweaked version of what was replied in my mailing list question.
It works pretty sweet and almost outperformed mod_wsgi 2x in testing hits to a simple pylons app served page.
Hope that helps.
I got cherokee + uwsgi + django running on lucid. It was a little tricky getting going (figuring out how to point uwsgi to the wsgi file was the hardest part for me, too), but I'm quite happy with the results. I documented the steps I took at http://blog.swwomm.com/2010/06/cherokee-django.html.
There seems to be an issue with the 'make' method of installation on the uwsgi docs. Use 'python uwsgiconfig.py --build' instead. That worked for me. Cherokee, Django running on Ubuntu 10.10.
Related
i have some reasons witch i am stuck to use django on windows machine. i was wondering how to configure django on a windows sesrver 2012 r2 with iis 8.5. so i followed the tutorial here.
i did what the tutorial says and it is pretty much straight forward what i am gonna do for any kind of application i want to run with iis.
but i get the following error the fastcgi process exited unexpectedly.
here is what i have provided as executable for wfastcgi module:
E:\venvs\...\Scripts\python.exe|E:\venvs\...\Lib\site-packages\wfastcgi.py
i removed the wfastcgi.py part after | from handler mapping and error changed to script processor could not find the config for fastcgi configuration and i figured out the error must be related to the wfastcgi.py file. but i could not find the issue here. so i was wondering what can be the issue? and what are my options are here.
has any one been able to use django on a windows machine?? jsut in case my python version is python 3.6
I had the exact same problem as you but managed to solve this by using Python 3.4.2 version. Follow the exact steps as described in this tutorial Django with IIS and avoid using Python 3.5 or above because it seems that there are compatibility issues. The stack I used was IIS version 10, Windows 10, Python 3.4.2 and Django 1.11.2.
Upgrading wfastcgi to the latest version
pip install wfastcgi --upgrade
solved it for me: Python 3.6.6, wfastcgi 3.0.0
In my Case I was facing the same issue i.e. enter image description here
Mine is a Django App used for APIs that queries data from back-end platforms. This issue was only for specific filters that the API was using in queries while for other values in filters it worked great.
My Config file did not have a fastCgi tag and I added below mentioned part to top of system.webServer in config file. Yes off course it gave few errors here and there corresponding to activityTimeout and requestTimeout. Tried increasing up-to 900 and 601 respectively and then it worked for me. But could not understand cause of the issue as query that API was running for which i was facing this issue was not taking that long at all. I would like to understand that.
<fastCgi>
<application fullPath="D:\Python34\python.exe|D:\Python34\Scripts\wfastcgi.py"
arguments=""
maxInstances="4"
idleTimeout="300"
activityTimeout="900"
requestTimeout="601"
instanceMaxRequests="10000"
protocol="NamedPipe"
flushNamedPipe="false">
</application>
</fastCgi>
Firstly, the OS I am working in is Fedora 20.
It seems like every way that is mentioned using Django and Apache is either deprecated, or there is no documentation at all.
I have tried mod_wsgi, and I have it all installed, but there is conflicting documentation. One says you should have a django.wsgi (old Django has this), and more recent documentation say you should have wsgi.py. I have tried both methods and all sorts of different things in the httpd.conf file, nothing works, and it all comes back with Forbidden. Also when just trying the Hello World script it always return an internal server error.
I then tried uwsgi. I can use this to get a uwsgi server up, and this seems to basically work in a similar fashion to just using python3 manage.py runserver, so I installed mod_proxy_uwsgi module for Apache, and there is absolutely no documentation on using this, so I just did something like ProxyPass / wsgi//localhost:8000/ in the httpd.conf. All this does is also returning an internal server error.
The main answer I want is: How exactly do I deploy a Django 1.6 project that uses Python 3, onto Apache?
This didn't work for you? It is listed under Django 1.6... then again, Python 3.x is still kind of iffy for a lot of stuff.
https://docs.djangoproject.com/en/1.6/howto/deployment/wsgi/modwsgi/
This has been resolved. As it turns out, SELinux was blocking httpd from accessing my Django project. I just used the following command then restarted the computer:
setsebool -P httpd_read_user_content 1
setsebool -P httpd_enable_homedirs 1
This will allow MOD_WSGI to work properly for deployment.
I am looking at getting python up and running with my WAMP setup.
I need it to test some py apps I am learning to build.
I see that Mod_wsgi project was terminated and that was pretty much the only way I found on how to run python on WAMP.
Can anyone advise how to get it up and running?
Thank you so much
mod_wsgi is an active, working project, and you have essentially answered your own question, you should use it.
You may have been thinking of mod_python, a different, discontinuted project that has been superseeded by mod_wsgi.
I would suggest you follow this guide.
Ok, so I made this application in Bottle that uses the NLTK package. It works fine on my computer which has all neccesary libraries installed, however, I can't get it to work on Google's App Engine. It gives these errors:
AttributeError: 'module' object has no attribute 'getuid'
I searched around and think this is a limitation of GAE, so I tried to use Alwaysdata and host my app there. However over there I have the problem that the YAML module is not installed. I tried to install it but access was denied.
creating /usr/local/lib/python2.6/site-packages/yaml
error: could not create '/usr/local/lib/python2.6/site-packages/yaml': Permission denied
So now I am stuck. This is the problem I walk into a lot. It all works fine on my computer, but then I can't get it to work online. Is this because of GAE limitations, alwaysdata limitations? So I guess I am asking where and how could I deploy best?
Is it more easy when I rent my own server and have full access there? Does that work as if it were my own computer and I can install everything?
Let me know if I need to provide more information, I'm pretty clueless.
I realise that you've already found an answer, but for other people looking for Python bottle hosting. PythonAnywhere has a quickstart option for deploying and hosting bottle apps now.
This is a three or four click wizard process that will have a barebones bottle application running in a 10 seconds. Letting you then build from there.
I've had great success running all different types of Python frameworks on WebFaction - http://www.webfaction.com/
Their support is awesome, instant replies to any problems I face. You get SSH access and can install your own modules, virtual-envs etc. You can run sites as a Custom Application listening on a port number, so you can basically run anything.
Here's a thread on how to setup a Bottle app with them: http://community.webfaction.com/questions/3998/how-to-setup-a-python-bottle-application
All that for $8.50/month if you pay a year upfront. http://www.webfaction.com/services/hosting
I can't recommend them enough.
Edit: Thought it wise to mention, I've written apps that use the NLTK and they've run on WebFaction with no troubles.
I tried a lot and was not able to set python with django and wastd full day.
I just found this
http://bitnami.org/stack/djangostack
Is that good for development and alos does it has mod_wsgi enabled on apache.
I want to make sure that , everything is ok , so that i can start building app on this
IF there are any other alternatives
http://www.instantdjango.com is a good click-and-go dev stack for Windows users. It bundles Python which is otherwise 80% of the hassle.
I suggest you be cautious when you deploy to a server though as a Django install on Linux may differ... But that's a problem you've got some time to think about.