29 lines
1008 B
Docker
29 lines
1008 B
Docker
# syntax=docker/dockerfile:1
|
|
FROM python:3.11
|
|
#FROM debian:stable
|
|
#FROM ubuntu:latest
|
|
#FROM postgres:alpine
|
|
|
|
#ENV POSTGRES_USER=RocksForMedia
|
|
#ENV POSTGRES_PASSWORD=CHANGE-ME
|
|
#ENV POSTGRES_DB=RocksForMediaDB
|
|
|
|
WORKDIR /RocksForMedia
|
|
|
|
COPY . .
|
|
RUN export $(sed '/#/d' src/.env | xargs)
|
|
#RUN apt update
|
|
#RUN apt install postgresql postgresql-client postgresql-contrib git sudo -y
|
|
#RUN apt install git -y
|
|
RUN git config --global url.https://github.com/.insteadOf git://github.com/
|
|
#RUN sudo -u postgres createuser -w -e $DODB_USER
|
|
#RUN sudo -u postgres createdb --owner=$DODB_USER $DODB_NAME 'contains all the information for the RocksForMedia instance on this device'
|
|
#RUN sudo -u postgres psql -c "ALTER USER $DODB_USER WITH PASSWORD '$DODB_PASS';"
|
|
|
|
RUN pip install -r src/requirements.txt
|
|
#RUN python3 src/manage.py makemigrations
|
|
#RUN python3 src/manage.py migrate
|
|
#RUN python3 src/manage.py createsuperuser --noinput --email $DJANGO_SUPERUSER_EMAIL
|
|
CMD ["python3", "src/manage.py", "runserver"]
|
|
EXPOSE 8890
|