add crontab file
This commit is contained in:
parent
52a9d68e6b
commit
20b9100624
14
dockerfile
14
dockerfile
@ -1,4 +1,10 @@
|
||||
FROM mysql:latest
|
||||
COPY backup.sh /usr/local/bin/
|
||||
RUN chmod +x /usr/loca/bin/backup.sh
|
||||
CMD ["cron","-f"]
|
||||
FROM mysql:8-debian
|
||||
RUN apt-get update --allow-unauthenticated --allow-insecure-repositories
|
||||
RUN apt-get -y install -qq --force-yes cron
|
||||
RUN echo "Log Start" >> /var/log/cron.log
|
||||
RUN mkdir /backup
|
||||
ADD backup.sh /usr/local/bin/
|
||||
ADD mysqlCron /etc/cron.d/mysqlCron
|
||||
RUN chmod 0644 /etc/cron.d/mysqlCron
|
||||
RUN chmod 0744 /usr/local/bin/backup.sh
|
||||
CMD cron && tail -f /var/log/cron.log
|
||||
Loading…
x
Reference in New Issue
Block a user