19 lines
395 B
Bash
19 lines
395 B
Bash
![]() |
#!/bin/sh
|
||
|
cd /app
|
||
|
|
||
|
# si no existe directorio de ambiente, se crea
|
||
|
if [ ! -d /app/libs ]; then
|
||
|
python -m venv libs
|
||
|
. ./libs/bin/activate
|
||
|
pip install -r requirements.txt
|
||
|
fi
|
||
|
|
||
|
# activar ambiente con dependencias
|
||
|
. ./libs/bin/activate
|
||
|
|
||
|
if [ ! -d /app/project ]; then
|
||
|
django-admin startproject project
|
||
|
fi
|
||
|
|
||
|
# iniciar servidor con puerto 8000
|
||
|
python /app/project/manage.py runserver 0.0.0.0:8000
|