Este es un proyecto Django. Siga las siguientes instrucciones para configurarlo en su máquina local.
- Python 3.x
- pip
- Homebrew (opcional pero recomendado para algunas dependencias)
git clone https://github.com/AranzaGtz/SistemaINADE2.git
cd SistemaINADE2-
Crear el entorno virtual:
python -m venv venv
-
En macOS y Linux:
source venv/bin/activate -
En Windows:
venv\Scripts\activate
-
Instalar Homebrew (opcional):
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" -
Añadir Homebrew a tu PATH:
(echo; echo 'eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"') >> /home/ubuntu/.bashrc eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)" ``
-
Instalar las dependencias necesarias para WeasyPrint:
brew install pango gdk-pixbuf cairo libffi
-
Si estás en un sistema Ubuntu, también puedes instalar estas dependencias del sistema:
sudo apt-get install -y libcairo2-dev libjpeg-dev libgif-dev librsvg2-dev
-
Configurar PKG_CONFIG_PATH y LD_LIBRARY_PATH:
export PKG_CONFIG_PATH=/home/linuxbrew/.linuxbrew/lib/pkgconfig export LD_LIBRARY_PATH=/home/linuxbrew/.linuxbrew/lib echo 'export PKG_CONFIG_PATH=/home/linuxbrew/.linuxbrew/lib/pkgconfig' >> ~/.bashrc echo 'export LD_LIBRARY_PATH=/home/linuxbrew/.linuxbrew/lib' >> ~/.bashrc source ~/.bashrc
-
Instalar las dependencias del proyecto desde requirements.txt:
pip install -r requirements.txt
python manage.py makemigrations
python manage.py migratepython manage.py runserverPara acceder al proyecto, abra su navegador web y vaya a http://127.0.0.1:8000/.
¡Gracias por usar nuestro proyecto!