IngWeb / Dockerfile
chartManD's picture
Update files
5539fd6
raw
history blame
902 Bytes
# Definir la imagen
FROM debian:12.10
# Instalar Python y venv para entornos virtuales
RUN apt -y update
RUN apt install -y python3 python3-pip python3-django
#RUN python3 -m django --version [3.2.19]
# Pasos del tutorial de DJango
RUN mkdir itsz
WORKDIR itsz
RUN django-admin startproject miSitio
RUN ls
WORKDIR miSitio
# Algo para que funcionen
RUN touch db.sqlite3
RUN sed -i 's/ALLOWED_HOSTS = \[\]/ALLOWED_HOSTS = \["*"\]/g' miSitio/settings.py
# Crear app de Poll o encuestas
RUN python3 manage.py startapp polls
RUN ls -l
RUN cat urls.py
#COPY . .
RUN ls polls/
#CMD python3 manage.py runserver 0:7860
# Verificar si python esta instalado
# RUN which python || which python3 || which py
# Version Python
# RUN python3 --version
# Activar el entorno virutal
# RUN python3 -m venv django
# RUN python3 django/bin/activate
# Instalar DJango
# RUN python3 -m pip install Django==5.1.7