开发者

How and where to deploy my Python and BottlePy application

开发者 https://www.devze.com 2023-03-30 11:33 出处:网络
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.

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.

0

精彩评论

暂无评论...
验证码 换一张
取 消