Skip to content
Snippets Groups Projects
Verified Commit 94e391d7 authored by TheJoeCoder's avatar TheJoeCoder
Browse files

Demo db and cron reset

parent 5a868908
No related branches found
No related tags found
No related merge requests found
FROM debian:bookworm-slim
RUN apt-get update && apt-get install -y cron
COPY demo_cronjob /etc/cron.d/cronjob
RUN chmod 0644 /etc/cron.d/cronjob
RUN touch /var/log/cron.log
CMD cron && tail -f /var/log/cron.log
\ No newline at end of file
File added
0 */3 * * * /usr/bin/cp /home/app/web/db.demo.sqlite3 /home/app/web/db.sqlite3 >> /var/log/cron.log 2>&1
......@@ -27,7 +27,7 @@ services:
soft: 65536 # Maximum number of open files for the opensearch user - set to at least 65536
hard: 65536
volumes:
- demo_opensearch:/usr/share/opensearch/data # Creates volume called opensearch-data1 and mounts it to the container
- demo_opensearch:/usr/share/opensearch/data
expose:
- 9200
- 9600
......@@ -47,6 +47,14 @@ services:
networks:
- librarydemo
cron:
build:
context: .
dockerfile: Dockerfile.cron.demo
volumes:
- ./db.sqlite3:/home/app/web/db.sqlite3
- ./db.demo.sqlite3:/home/app/web/db.demo.sqlite3
volumes:
demo_static:
demo_media:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment