Add: basic Dockerfile

This commit is contained in:
Aroy-Art 2023-08-02 13:46:52 +02:00
parent ce63a2fee9
commit dec0257fea
Signed by: Aroy
GPG key ID: 583642324A1D2070

21
Dockerfile Normal file
View file

@ -0,0 +1,21 @@
# Use an official Python runtime as a parent image
FROM python:3.10-slim-bullseye
# Set the working directory to /app
WORKDIR /app
# Copy the current directory contents into the container at /app
COPY . /app
# Install any needed packages specified in requirements.txt
RUN export PYTHONPATH=/usr/bin/python && pip install --no-cache-dir -r requirements.txt
# RUN pip install --no-cache-dir -r requirements.txt
# Make port 8000 available to the world outside this container
EXPOSE 8000
# Define environment variable
#ENV DJANGO_SETTINGS_MODULE=mysite.settings.production
# Run the command to start Django
CMD ["python", "archivist/manage.py", "runserver", "0.0.0.0:8000"]