Skip to content

Commit

Permalink
Remove bash_profiles from Python frameworks
Browse files Browse the repository at this point in the history
bash_profile contents placed into install files and setup files for:
- API-Hour
- Cherrypy
- Django
  • Loading branch information
LadyMozzarella committed Apr 4, 2015
1 parent ec15f3b commit 8f6f322
Show file tree
Hide file tree
Showing 12 changed files with 60 additions and 29 deletions.
4 changes: 0 additions & 4 deletions frameworks/Python/API-Hour/bash_profile.sh

This file was deleted.

5 changes: 5 additions & 0 deletions frameworks/Python/API-Hour/install.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
#!/bin/bash

export PY3_ROOT=$IROOT/py3
export PY3=$PY3_ROOT/bin/python
export PY3_PIP=$PY3_ROOT/bin/pip3
export PY3_API_HOUR=$PY3_ROOT/bin/api_hour

mkdir -p $IROOT/.pip_cache
export PIP_DOWNLOAD_CACHE=$IROOT/.pip_cache

Expand Down
5 changes: 5 additions & 0 deletions frameworks/Python/API-Hour/setup.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
#!/bin/bash

export PY3_ROOT=$IROOT/py3
export PY3=$PY3_ROOT/bin/python
export PY3_PIP=$PY3_ROOT/bin/pip3
export PY3_API_HOUR=$PY3_ROOT/bin/api_hour

$PY3_API_HOUR -ac --chdir=hello/ --config_dir=hello/etc/hello/ hello:Container &
7 changes: 0 additions & 7 deletions frameworks/Python/cherrypy/bash_profile.sh

This file was deleted.

8 changes: 8 additions & 0 deletions frameworks/Python/cherrypy/install.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
#!/bin/bash

export PY2_ROOT=$IROOT/py2
export PY2=$PY2_ROOT/bin/python
export PY2_PIP=$PY2_ROOT/bin/pip

export PY3_ROOT=$IROOT/py3
export PY3=$PY3_ROOT/bin/python3
export PY3_PIP=$PY3_ROOT/bin/pip3

mkdir -p $IROOT/.pip_cache
export PIP_DOWNLOAD_CACHE=$IROOT/.pip_cache

Expand Down
4 changes: 4 additions & 0 deletions frameworks/Python/cherrypy/setup.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
#!/bin/bash

export PY2_ROOT=$IROOT/py2
export PY2=$PY2_ROOT/bin/python
export PY2_PIP=$PY2_ROOT/bin/pip

$PY2 app.py &
4 changes: 4 additions & 0 deletions frameworks/Python/cherrypy/setup_py3.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
#!/bin/bash

export PY3_ROOT=$IROOT/py3
export PY3=$PY3_ROOT/bin/python3
export PY3_PIP=$PY3_ROOT/bin/pip3

$PY3 app.py &
14 changes: 0 additions & 14 deletions frameworks/Python/django/bash_profile.sh

This file was deleted.

17 changes: 16 additions & 1 deletion frameworks/Python/django/install.sh
Original file line number Diff line number Diff line change
@@ -1,10 +1,25 @@
#!/bin/bash

export PY2_ROOT=$IROOT/py2
export PY2=$PY2_ROOT/bin/python
export PY2_PIP=$PY2_ROOT/bin/pip
export PY2_GUNICORN=$PY2_ROOT/bin/gunicorn

export PYPY_ROOT=$IROOT/pypy
export PYPY=$PYPY_ROOT/bin/python
export PYPY_PIP=$PYPY_ROOT/bin/pip
export PYPY_GUNICORN=$PYPY_ROOT/bin/gunicorn

export PY3_ROOT=$IROOT/py3
export PY3=$PY3_ROOT/bin/python
export PY3_PIP=$PY3_ROOT/bin/pip3
export PY3_GUNICORN=$PY3_ROOT/bin/gunicorn

mkdir -p $IROOT/.pip_cache
export PIP_DOWNLOAD_CACHE=$IROOT/.pip_cache

fw_depends python2 python3

$IROOT/py2/bin/pip install --install-option="--prefix=${IROOT}/py2" -r $TROOT/requirements.txt

$IROOT/py3/bin/pip3 install --install-option="--prefix=${IROOT}/py3" -r $TROOT/requirements.txt
$IROOT/py3/bin/pip3 install --install-option="--prefix=${IROOT}/py3" -r $TROOT/requirements.txt
7 changes: 6 additions & 1 deletion frameworks/Python/django/setup.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
#!/bin/bash

$PY2_GUNICORN --pid=gunicorn.pid hello.wsgi:application -c gunicorn_conf.py --env DJANGO_DB=mysql &
export PY2_ROOT=$IROOT/py2
export PY2=$PY2_ROOT/bin/python
export PY2_PIP=$PY2_ROOT/bin/pip
export PY2_GUNICORN=$PY2_ROOT/bin/gunicorn

$PY2_GUNICORN --pid=gunicorn.pid hello.wsgi:application -c gunicorn_conf.py --env DJANGO_DB=mysql &
7 changes: 6 additions & 1 deletion frameworks/Python/django/setup_pg.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
#!/bin/bash

$PY2_GUNICORN --pid=gunicorn.pid hello.wsgi:application -c gunicorn_conf.py --env DJANGO_DB=postgresql_psycopg2 &
export PY2_ROOT=$IROOT/py2
export PY2=$PY2_ROOT/bin/python
export PY2_PIP=$PY2_ROOT/bin/pip
export PY2_GUNICORN=$PY2_ROOT/bin/gunicorn

$PY2_GUNICORN --pid=gunicorn.pid hello.wsgi:application -c gunicorn_conf.py --env DJANGO_DB=postgresql_psycopg2 &
7 changes: 6 additions & 1 deletion frameworks/Python/django/setup_py3.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
#!/bin/bash

$PY3_GUNICORN --pid=gunicorn.pid hello.wsgi:application -c gunicorn_conf.py --env DJANGO_DB=mysql &
export PY3_ROOT=$IROOT/py3
export PY3=$PY3_ROOT/bin/python
export PY3_PIP=$PY3_ROOT/bin/pip3
export PY3_GUNICORN=$PY3_ROOT/bin/gunicorn

$PY3_GUNICORN --pid=gunicorn.pid hello.wsgi:application -c gunicorn_conf.py --env DJANGO_DB=mysql &

0 comments on commit 8f6f322

Please sign in to comment.