Skip to content

Instantly share code, notes, and snippets.

@JensRantil
Created October 11, 2013 21:24
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Embed
What would you like to do?
Example of creating a "supertask" in Fabric. The tasks spawns a couple of smaller tasks.
from fabric.api import *
from __future__ import print_function
@task
def supertask():
execute(create_user)
execute(deploy)
@task
@host('root@host')
def create_user():
print("Creating user...")
@task
@host('user@host')
def deploy():
print("Deploying...")
fab supertask
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment