From d820a35c739a5c28cfcbd30f23a1a733bb97c7b1 Mon Sep 17 00:00:00 2001 From: Alexis Metaireau Date: Wed, 10 Aug 2011 01:31:59 +0200 Subject: [PATCH] Add a fabfile to simplofy the deployment. Fixes #13 --- fabfile.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 fabfile.py diff --git a/fabfile.py b/fabfile.py new file mode 100644 index 00000000..41f7ddcb --- /dev/null +++ b/fabfile.py @@ -0,0 +1,13 @@ +from fabric.api import * + +env.hosts = ['lolnet.org:20002'] +env.shell = "/usr/local/bin/bash -c" +env.path = "/usr/local/bin/:/usr/bin/" + +def deploy(): + with cd('/usr/local/www/notmyidea.org/ihatemoney'): + sudo('git pull', user="www") + sudo('supervisorctl restart ihatemoney') + +def whoami(): + run('/usr/bin/whoami')