Fabric helpers¶
Core¶
Django¶
-
fusionbox.fabric.django.obfuscate()[source]¶ Compile all source files to byte code, then remove them.
-
fusionbox.fabric.django.obfuscate_decorator(role)[source]¶ Given a fabric action, this will run obfuscate() after it with config settings for the specified role.
-
fusionbox.fabric.django.run_subprocesses(*args, **kwds)[source]¶ Returns a list of tuples of command, Popen object. During __close__, the list of processes is polled for unfinished processes and attempts to close them.
-
fusionbox.fabric.django.runserver()[source]¶ Runs the local django server, starting up celery workers and/or the solr server if needed.
The following fb_env variables must be present in your fabfile for their related processes to be started. Each should be a 2-tuple of directory and command to run.
runserver_cmd:('.', './manage.py runserver')celery_cmd:('.', './manage.py celery worker -c 2 --autoreload')solr_cmd:('solr', 'java -jar start.jar')
FBORM¶
Utilities¶
-
fusionbox.fabric.utils.files_changed(version, files)[source]¶ Checks if anything in
fileshas changed between version and local HEAD.
Git utilities¶
-
fusionbox.fabric.git.has_git_branch(branch)[source]¶ Checks if
branchis available in the remote git repository.
Update methods¶
-
fusionbox.fabric.update.get_update_function()[source]¶ Returns the update function which will be used to update the remote site files based on the
fb_env.transport_methodconfig setting.