Created
October 25, 2012 07:16
-
-
Save potix2/3951125 to your computer and use it in GitHub Desktop.
fabric runs_once test
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from fabric.api import env, task | |
from fabric.decorators import runs_once | |
env.hosts = ['host1','host2','host3'] | |
@runs_once | |
def _pull(): | |
print "pull artifacts" | |
@task | |
def deploy(): | |
_pull() | |
print("deploying on %s" % env.host_string) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment