From 0b0b61a6dda1e777af939c5849e8b6c64cbc239f Mon Sep 17 00:00:00 2001 From: root Date: Tue, 31 May 2022 13:03:10 +0200 Subject: [PATCH] Add cron to the docker --- Dockerfile | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 0f45c27..52a987a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -4,4 +4,11 @@ WORKDIR /app COPY ./ /app -RUN composer install \ No newline at end of file +RUN composer install + +RUN (crontab -l ; echo "*/2 * * * * /usr/local/bin/php /app/oil refine server:ping")| crontab - +RUN (crontab -l ; echo "*/2 * * * * /usr/local/bin/php /app/oil refine server:ping")| crontab - +RUN (crontab -l ; echo "*/5 * * * * /usr/local/bin/php /app/oil refine server:browseServers")| crontab - +RUN (crontab -l ; echo "*/5 * * * * /usr/local/bin/php /app/oil refine server:browseServers")| crontab - +RUN (crontab -l ; echo "0 5 1 * * /usr/local/bin/php /app/oil refine server:checkNotFound")| crontab - +RUN (crontab -l ; echo "0 5 1 * * /usr/local/bin/php /app/oil refine server:checkNotFound")| crontab - \ No newline at end of file