Skip to content

Instantly share code, notes, and snippets.

@naosim
Created May 5, 2015 23:44
Show Gist options
  • Save naosim/5d8242325a61f7919f84 to your computer and use it in GitHub Desktop.
Save naosim/5d8242325a61f7919f84 to your computer and use it in GitHub Desktop.
Fabricデプロイ
# example
# fab -H [hostname] -u [user] -i [pubkey] deploy:[work dir]
from fabric.api import cd, run
def deploy(dir):
with cd (dir):
run("ls")
run("git pull")
run("npm install")
run("sh stop.sh")
run("sh start.sh")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment