| commit | author | age | ||
| 83c3f6 | 1 | # Use sizif-base as a base image. There should be most of the stuff already installed |
| SP | 2 | FROM sizif-base:latest |
| 3 | WORKDIR /app | |
| 4 | # Install any needed packages specified in requirements.txt | |
| 5 | #RUN apt-get update && apt-get install -y curl gnupg | |
| 6 | #RUN curl -sL https://deb.nodesource.com/setup_10.x > setup_10.x | |
| 7 | #RUN npm install -g bower | |
| 8 | RUN git clone https://git.penic.eu/r/havoc/berki-parse.git && git clone https://git.penic.eu/r/havoc/sizif-ocr.git -b downstairs_scanner | |
| 9 | WORKDIR berki-parse | |
| 10 | RUN python3 ./setup.py install | |
| 11 | WORKDIR ../sizif-ocr | |
| 12 | RUN python3 ./setup.py install | |
| 13 | ||
| 14 | WORKDIR /app | |
| 15 | # Copy the current directory contents into the container at /app | |
| 16 | COPY . /app | |
| 17 | ||
| 18 | RUN apt-get -y install locales-all nginx | |
| 19 | RUN pip3 install gunicorn psycopg2-binary && python3 ./manage.py makemigrations && python3 ./manage.py migrate && python3 ./manage.py bower install | |
| 20 | ||
| 21 | COPY nginx.conf /etc/nginx/sites-available/default | |
| 22 | ||
| 23 | ||
| 24 | RUN python3 ./manage.py collectstatic --noinput | |
| 25 | STOPSIGNAL SIGINT | |
| 26 | EXPOSE 8000 | |
| 27 | ENV DJANGO_SETTINGS_MODULE="aoi.settings" | |
| 28 | ENV LC_ALL en_US.UTF-8 | |
| 29 | VOLUME '/app/scans' '/app/exams' '/app/inputscans' '/app/database' '/app/settings' '/var/log/sizif/' '/app/processedscans' | |
| 30 | #ENTRYPOINT ["python3", "manage.py"] | |
| 31 | #CMD ["runserver", "0.0.0.0:8000"] | |
| 32 | ||
| 33 | #CMD ["gunicorn", "--chdir", "/app", "--bind", ":8888", "aoi.wsgi:application"] | |
| 34 | CMD ./entrypoint.sh | |