Skip to content

Commit

Permalink
fabfile: add prod
Browse files Browse the repository at this point in the history
  • Loading branch information
jalavik committed Nov 3, 2014
1 parent 43be51a commit 719feef
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion fabfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,22 @@
env.directory = '/opt' # remote directory

env.roledefs = {
'prod': ['inspirelabsvm01'],
'dev01': ['inspirevm08.cern.ch'],
'dev02': ['inspirevm11.cern.ch'],
}


@task
def prod():
"""
Activate configuration for INSPIRE DEV server.
"""
env.roles = ['prod']
env.site_url = "http://inspirevmlabs01.cern.ch"
env.site_secure_url = "https://inspirevmlabs01.cern.ch"


@task
def vm08():
"""
Expand Down Expand Up @@ -100,7 +111,7 @@ def install():
sudo("pip install /afs/cern.ch/project/inspire/repo/inspire-configuration-dist/dist/inspireconf-dev.tar.gz --upgrade")
# post install
sudo("inveniomanage collect")
with(settings(warn_only=True)):
with warn_only():
# Compile base Invenio translatation to avoid translation error
prefix_folder = sudo('python -c "import invenio; print(invenio.__path__[0])"')
prefix_folder = prefix_folder.split("\n")
Expand Down

0 comments on commit 719feef

Please sign in to comment.