login community faq

First, is there a "recommended" way to set up Gunicorn and Django on Webfaction?

Second, what, if any, are things we should be aware of when deploying with Gunicorn on WebFaction (e.g. memory usage, etc...)?

Cheers!

asked Jan 30 '11 at 18:55

danaw's gravatar image

danaw
64

Hi,

There is no recommended way, as such.

I think if you limit the number of processes to 1 or 2 until you see how much RAM it is going to use then you can increase or modify as needed.

Hope that helps!

(Jan 30 '11 at 18:58) klynton ♦♦ klynton's gravatar image

Yeah that is a good point considering I had my app calculating the cores on the machine and doubling it for the amount of workers... which I think ends up being like 8-16 workers... way too many for 80mb of RAM.

(Jan 30 '11 at 19:47) danaw danaw's gravatar image

8 - 16 workers would be a bit too much for 80MB of RAM unless your application was really small.

(Jan 30 '11 at 19:51) klynton ♦♦ klynton's gravatar image

Yeah, I was using something like 256mb or something equally insane. Got my processes shut off automatically :)

With 2 workers, things seem to be running well.

(Feb 01 '11 at 18:26) danaw danaw's gravatar image

Hi,

Thanks for reporting back what you found! Now we do have a set of best practices for Gunicorn. :)

(Feb 01 '11 at 18:36) klynton ♦♦ klynton's gravatar image

Like I have been doing a lot of searching and probing to get this done easily, I might as well share the fabric script I wrote to deploy django/gunicorn. It is git specific, but you can checkout how its done easily from the script itself.

https://github.com/ashwoods/webfaction-django-fabfile

answered Oct 06 '11 at 10:40

ashwoods's gravatar image

ashwoods
111

Thanks for sharing!

(Oct 06 '11 at 11:18) seanf ♦♦ seanf's gravatar image
Your answer
If you have an answer to the above question, then use the form below. Otherwise, use the appropriate 'add new comment' button above to post your feedback.
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Tags:

×641
×10

Asked: Jan 30 '11 at 18:55

Seen: 1,765 times

Last updated: Oct 06 '11 at 11:18

Plans & prices    Sign up    Why WebFaction?    Contact us    Affiliate program    Support    Legal    Jobs    Blog    Control panel login
Powered by OSQA
© Copyright 2003-2012 Swarma Limited - WebFaction is a service of Swarma Limited