diff --git a/compose/osmcha.yml b/compose/osmcha.yml index c7793819..20280fdc 100644 --- a/compose/osmcha.yml +++ b/compose/osmcha.yml @@ -19,6 +19,6 @@ services: context: ../images/osmcha dockerfile: Dockerfile ports: - - '80:80' + - '8000:8000' env_file: - ../envs/.env.osmcha diff --git a/images/osmcha/Dockerfile b/images/osmcha/Dockerfile index 309a469d..55950148 100644 --- a/images/osmcha/Dockerfile +++ b/images/osmcha/Dockerfile @@ -20,6 +20,7 @@ ENV BACKEND_VERSION v4.17.0 RUN git clone https://github.com/willemarcel/osmcha-django . RUN git checkout $BACKEND_VERSION RUN pip3 install -r requirements/production.txt +RUN pip3 install -r requirements/local.txt RUN curl -o /usr/local/bin/watchbot https://s3.amazonaws.com/watchbot-binaries/linux/v5.0.0/watchbot RUN chmod +x /usr/local/bin/watchbot @@ -36,5 +37,9 @@ RUN curl -sL https://github.com/mapbox/decrypt-kms-env/archive/v1.0.3.tar.gz | t ENV DJANGO_ROOT /app ENV DJANGO_SETTINGS_MODULE config.settings.production ENV C_FORCE_ROOT True + +RUN echo "alias python=python3" >> ~/.bashrc +RUN echo "alias pip=pip3" >> ~/.bashrc + COPY ./start.sh . -ENTRYPOINT ["./start.sh"] \ No newline at end of file +CMD ./start.sh \ No newline at end of file diff --git a/images/osmcha/start.sh b/images/osmcha/start.sh index c33cd382..50d654af 100755 --- a/images/osmcha/start.sh +++ b/images/osmcha/start.sh @@ -1,4 +1,4 @@ #!/usr/bin/env bash set -e python3 manage.py migrate -python3 manage.py runserver_plus 0.0.0.0:8000 \ No newline at end of file +python3 manage.py runserver 0.0.0.0:8000 --nothreading --noreload