forked from mohaps/ImageSegmentation
-
Notifications
You must be signed in to change notification settings - Fork 0
/
fabfile.py
35 lines (29 loc) · 825 Bytes
/
fabfile.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
from fabric.api import env,local,run,sudo,put,cd,lcd,puts,task
from fabric.operations import local as lrun, run
from fabric.state import env
import os,sys,logging
logging.basicConfig(level=logging.INFO,
format='%(asctime)s %(name)-12s %(levelname)-8s %(message)s',
datefmt='%m-%d %H:%M',
filename='logs/fab.log',
filemode='a')
sys.path.insert(1, os.path.join(os.path.abspath('.'), 'appcode/vendor'))
vendor_dir = os.path.join(os.path.dirname(__file__), 'appcode/vendor')
@task
def test():
"""
Test GAE version
"""
local('dev_appserver.py .')
@task
def deploy():
"""
Deploy GAE version
"""
local('appcfg.py --oauth2 update . ')
@task
def clear():
"""
remove logs
"""
local('rm logs/*.log &')