Files
api2/fabfile.py

18 lines
485 B
Python

from fabric.api import env, lcd, local, abort
def staging():
env.environment = 'staging'
def production():
env.environment = 'production'
def cloudformation_update():
with lcd('./cloudformation/'):
local('make update-stack ENVIRONMENT_NAME={0}'.format(env.environment))
def deploy():
if env.environment != 'staging':
abort('Local deploy to staging only. Production deploy is automatic when merging to master.')
local('make publish-to-staging')