diff options
Diffstat (limited to 'cron/Dockerfile')
-rwxr-xr-x | cron/Dockerfile | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/cron/Dockerfile b/cron/Dockerfile new file mode 100755 index 0000000..21aa4e4 --- /dev/null +++ b/cron/Dockerfile @@ -0,0 +1,12 @@ +FROM reg.reaweb.uk/smallytchannelbot +MAINTAINER Eden Attenborough "eddie.atten.ea29@gmail.com" +ARG DEBIAN_FRONTEND=noninteractive +RUN apt-get install -y tzdata cron mysql-client +COPY . /app +WORKDIR /app +RUN pip3 install -r cron/requirements.txt + +RUN echo "@daily root python3 /app/cron/daily.py > /proc/1/fd/1 2>/proc/1/fd/2" > /etc/crontab +RUN echo "@hourly root python3 /app/cron/hourly.py > /proc/1/fd/1 2>/proc/1/fd/2" >> /etc/crontab +ENTRYPOINT ["bash"] +CMD ["entrypoint.sh"] |