1. Sebastian Schulz
  2. django-deployment


django-deployment /

Filename Size Date modified Message
137 B
1.1 KB
1.5 KB
3.0 KB
957 B

Django deployment script

This package provides a fabric script for building and maintaining django web application hosting. The goal is to simplify the deploy process.

Keep in mind, that this script ist still under construction. If you have found a bug or you have a suggestion, contact me or fire an issue or send a pull request.

Source code: https://bitbucket.org/ses_schulz/django-deployment/src

Bug tracker: https://bitbucket.org/ses_schulz/django-deployment/issues/


  • Fabric >= 1.4.0
  • Django >= 1.3.1


pip install git+ssh://git@bitbucket.org/ses_schulz/django-deployment.git


Create in the root directory of your project a fabfile.py.


from fabric.api import env, task
import deploy

def config_test():
    env.hosts = ['example.com', ]
    env.user = "username"
    env.VIRTUAL_ENV = "/home/dir-of-project"
    env.VCS_URL = 'http://example.com/my-git-repo'
    env.DJANGO_SETTINGS_MODULE = 'settings'
    env.LOCAL_SETTINGS = 'config/local.py'
    env.REMOTE_SETTINGS = '%(VIRTUAL_ENV)s/src/settings/local.py' % env
    env.DJANGO_FCGI_PID = '%(VIRTUAL_ENV)s/django-fcgi.pid' % env

Now you can deploy your django project the first time.


fab config_test deploy.first_deploy

New deployments, you can realize with this command


fab config_test deploy