librarynotices/Dockerfile
Dan Hamik 9c0d0aa6c2
All checks were successful
/ Plan (push) Successful in 12s
/ Plan (pull_request) Successful in 11s
dockerfile changes
2024-11-25 14:07:05 -06:00

14 lines
521 B
Docker

FROM debian:bullseye-slim
#
RUN apt update && apt install cron apache2 python3 python3-pip -y
COPY crontab /etc/cron.d/crontab
COPY refresh.php /var/www/html/
COPY libnotices.py /usr/local/bin/
COPY requirements.txt /
RUN pip3 install -r /requirements.txt
RUN mkdir /var/www/.aws
RUN chmod +x /usr/local/bin/libnotices.py
RUN chown www-data:www-data /var/www -R
RUN apt clean
EXPOSE 80
CMD ["bash -c cron -l 8","bash -c su - www-data -s /bin/bash python3 /usr/local/bin/libnotices.py", "bash -c apache2ctl -D FOREGROUND"]