| 1 | |
| 2 | |
| 3 | python -m venv venv |
| 4 | |
| 5 | echo "export NGINX_HOST=localhost" >> venv/**/activate |
| 6 | echo "export DOMAIN=localhost" >> venv/**/activate |
| 7 | echo "export POSTGRES_USER=postgres" >> venv/**/activate |
| 8 | echo "export POSTGRES_PASSWORD=postgres" >> venv/**/activate |
| 9 | echo "export POSTGRES_DB=postgres" >> venv/**/activate |
| 10 | echo "export POSTGRES_HOST=localhost" >> venv/**/activate |
| 11 | echo "export POSTGRES_PORT=5821" >> venv/**/activate |
| 12 | |
| 13 | |
| 14 | echo "Activating virtual environment" |
| 15 | source venv/**/activate |
| 16 | while [ $? -ne 0 ]; do |
| 17 | echo "Failed to activate virtual environment, trying again in 1 second" |
| 18 | source venv/**/activate |
| 19 | sleep 1 |
| 20 | done |
| 21 | |
| 22 | |
| 23 | cd rango/backend |
| 24 | echo "Installing requirements" |
| 25 | pip install -r requirements.txt |
| 26 | while [ $? -ne 0 ]; do |
| 27 | echo "Failed to install requirements, trying again in 1 second" |
| 28 | pip install -r requirements.txt |
| 29 | sleep 1 |
| 30 | done |
| 31 | |
| 32 | |
| 33 | cd ../frontend |
| 34 | echo "Installing frontend requirements" |
| 35 | npm install |
| 36 | while [ $? -ne 0 ]; do |
| 37 | echo "Failed to install frontend requirements, trying again in 1 second" |
| 38 | npm install |
| 39 | sleep 1 |
| 40 | done |