librarynotices/Dockerfile

18 lines
573 B
Docker
Raw Normal View History

2024-11-25 12:53:31 -06:00
FROM debian:bullseye-slim
2024-11-25 13:24:36 -06:00
#
2024-11-25 15:06:17 -06:00
RUN apt update && apt install cron apache2 python3 python3-pip php libapache2-mod-php -y
RUN a2enmod php*
2024-11-25 12:53:31 -06:00
COPY crontab /etc/cron.d/crontab
COPY refresh.php /var/www/html/
COPY libnotices.py /usr/local/bin/
COPY requirements.txt /
2024-11-25 14:27:04 -06:00
COPY init.sh /
RUN chmod +x /init.sh
2024-11-25 12:53:31 -06:00
RUN pip3 install -r /requirements.txt
2024-11-25 13:53:56 -06:00
RUN mkdir /var/www/.aws
2024-11-25 12:53:31 -06:00
RUN chmod +x /usr/local/bin/libnotices.py
2024-11-25 13:53:56 -06:00
RUN chown www-data:www-data /var/www -R
2024-11-25 13:11:57 -06:00
RUN apt clean
EXPOSE 80
2024-11-25 14:27:04 -06:00
CMD ["/init.sh"]
#(cron -l 8 & ) && su - www-data -s /usr/local/bin/libnotices.py & apache2ctl -D FOREGROUND]