install_requirements.sh 773 Bytes

# Create a virtual env for Python3
cd ../
mkdir private
cd private/
PYTHON3=`which python3.5`
echo "python version available is : $PYTHON3"
#/opt/local/bin/python3.5
# create a venv_py35_pyros/ folder inside PYROS/private/
virtualenv venv_py3_pyros -p $PYTHON3

# Activate the virtual env
source ./venv_py3_pyros/bin/activate

# check that python is at least version 3
#python -V
PYTHON3env=`which python`
echo "python venv is : $PYTHON3env"

# Upgrade pip
pip install --upgrade pip
# Upgrade wheel
pip install --upgrade wheel

# Install the needed python packages
pip install -r ../install/REQUIREMENTS.txt

# Create a superuser pyrossu/pyrossu
cd ../src/
./manage.py makemigrations
./manage.py migrate
./manage.py createsuperuser --username pyros --email pyros@toto.fr