Softpedia
 


LINUX CATEGORIES:



GLOBAL PAGES >>
NEWS ARCHIVE >>
SOFTPEDIA REVIEWS >>
MEET THE EDITORS >>
WEEK'S BEST
  • Linux Kernel 3.9.6 / 3....
  • Linux Kernel 3.0.82 LTS...
  • KDE Software Compilatio...
  • PulseAudio 4.0
  • Wireshark 1.10.0
  • NetworkManager 0.9.8.2
  • LibreOffice 3.6.6 / 4.0...
  • SystemRescueCd 3.7.0
  • Linux Kernel 3.10 RC6
  • Ubuntu Tweak 0.8.5
  • Home > Linux > Internet > Django Plugins

    dploi-fabric 0.1.18

    Download button

    No screenshots available
    Downloads: 190  View global page NEW!  Tell us about an update
    User Rating:
    Rated by:
    NOT RATED
    0 user(s)
    Developer:

    License / Price:

    Last Updated:

    Category:
    Benjamin Wohlwend, Kristian Oellegaard and Stefan Foulis | More programs
    BSD License / FREE
    July 14th, 2012, 21:14 GMT
    ROOT / Internet / Django Plugins

     Read user reviews (0)  Refer to a friend  Subscribe

    dploi-fabric description

    Fabric scripts for easy deployment

    dploi-fabric is a set of reusable Fabric tasks. It uses the new-style task system of Fabric >= 1.2.

    Usage

    - Add dploi-fabric to your buildout environment (preferably in development_local.cfg, the servers have no use for it).

    - Create a fabfile.py as normal.

    - Pick and choose the modules and import them in the fabfile.py, e.g.:

     from fabric.decorators import task

     from dploi_fabric.db import pg # if project uses mysql, import "mysql" instead
     from dploi_fabric import supervisor, nginx
     from dploi_fabric import git, utils, buildout, south, django_utils, project

     from dploi_fabric.conf import load_settings

     @task
     def dev():
     load_settings('dev')

     @task
     def stage():
     load_settings('stage')

     @task
     def live():
     load_settings('live')

     @task
     def deploy():
     pg.dump.run()
     git.update()
     buildout.run()
     south.migrate.run()
     django_utils.collectstatic()
     supervisor.restart()
     supervisor.status()
     nginx.update_config_file()


    - in the project root, create a file deployment.py following this template:

     project_name = 'awesome_new_website'

     settings = {
     'dev': {
     'hosts': ['yourserver.com'],
     'path': '/home/awesome_new_website-dev/app/',
     'user': 'awesome_new_website-dev',
     'buildout_cfg': 'server_dev.cfg',
     'repo': 'git@github.com:youruser/awesome_new_website.git',
     'branch': 'master',
     'backup_dir': '/home/awesome_new_website-dev/tmp/', # Used for mysql/psql dumps
     'db_name': 'awesome_new_website-dev',
     'db_username': 'awesome_new_website-dev',
     'domains': ['sitename-dev.agency.com', 'www.sitename.com'],
     'domains_redirect': [
     {'domain': 'sitename.com', 'destination_domain': 'www.sitename.com'},
     ],
     'ssl': True,
     'ssl_key_path': '../config/ssl.key', # This must be uploaded manually, possibly by a task in the future
     'ssl_cert_path': '../config/ssl.crt', # This must be uploaded manually, possibly by a task in the future
     'basic_auth': False,
     'basic_auth_path': '../config/htpasswd', # This must be uploaded manually, possibly by a task in the future
     },
     }


     add settings for stage/live as needed.

    - call bin/fab --list for a list of commands

    Note: when using these tasks, all project-specific tasks have to be decorated with the @task decorator from fabric.api.

    Configuration file (config.ini)

    Remember to add config.ini, example:

     [static]

     /media/ = py_src/project/media/


    and/or

     [static]

     /static/ = %(static_files)s


    Other options

     [checkout]

     tool = buildout (default)

     tool = virtualenv

     [celery] (if the section is present, celery is enabled)

     [django]

     base = .

     base = project/

     base = py_src/project (doesnt work with buildout yet, as it would try to access py_src/project/bin/django)

     append_settings = true

     append_settings = false

     [static]

     (see above)

     /url-path/ = rel-path-filesystem/



    Product's homepage

    Requirements:

    · Python
    · Fabric

      


    TAGS:

    Fabric scripts | Fabric deployment | Fabric tasks | Fabric | scripts | deployment

    Go to top

    WindowsGamesDriversMacLinuxScriptsMobileHandheldNews

    SUBMIT PROGRAM   |   ADVERTISE   |   GET HELP   |   SEND US FEEDBACK   |   RSS FEEDS   |   UPDATE YOUR SOFTWARE   |   ROMANIAN FORUM