Deploy django apps to Amazon EC2 with ONE command

Fabulous will create an EC2 instance, install everything and deploy a blank django app. All in less than 2 minutes.

Process

Create server on EC2
Wait a few seconds for server to boot
Install packages
Create virtualenv
Install django in virtualenv
Install gunicorn in virtualenv
Setup and run supervisor
The setup

nginx
gunicorn
supervisor
memcached
virtualenv
virtualenvwrapper
git

PhantomJS

PhantomJS is a headless WebKit scriptable with a JavaScript API. It has fast and native support for various web standards: DOM handling, CSS selector, JSON, Canvas, and SVG.

PhantomJS is an optimal solution for:

HEADLESS WEBSITE TESTING
Run functional tests with frameworks such as Jasmine, QUnit, Mocha, Capybara, WebDriver, and many others. Learn more

SCREEN CAPTURE
Programmatically capture web contents, including SVG and Canvas. Create web site screenshots with thumbnail preview. Learn more

PAGE AUTOMATION
Access and manipulate webpages with the standard DOM API, or with usual libraries like jQuery.
Learn more

NETWORK MONITORING
Monitor page loading and export as standard HAR files. Automate performance analysis using YSlow and Jenkins. Learn more

Setting up Django in Virtualenv on WebFaction’s Apache with mod_wsgi

If you want to run a Django application on WebFaction, you may simply use their automatic application creation scripts. Unfortunately, if you want to place your application in a Virtualenv, the automatic installer will not help you. I’m sure that WebFaction will eventually add an installer to set this up, but for now, you can use the following tutorial. In this text we set up a Django project in a Virtualenv running on WebFaction’s Apache with mod_wsgi.

 

Background Processing with django celery Utilizing Redis as a Broker and supervisord as a Daemon on WebFaction

The reason we set the concurrency so low is because Celery takes up a good amount of memory, and you are likely limited with your memory consumption on WebFaction. The minimum amount of memory Celery can take will be however much it needs to run the main process (consuming messages, sending tasks to workers, etc), and a worker tasks that actually does stuff. Each of these will take up about 20-30MB of memory depending on the size of your Django app.