Dockerfile crontab fix
This commit is contained in:
15
Dockerfile
15
Dockerfile
@@ -1,23 +1,16 @@
|
|||||||
# Dockerfile - FPC Discord bot SSL támogatással
|
|
||||||
FROM debian:12-slim
|
FROM debian:12-slim
|
||||||
|
|
||||||
RUN apt-get update && apt-get install -y \
|
RUN apt-get update && apt-get install -y \
|
||||||
fpc fp-units-fcl fp-units-net tzdata curl jq \
|
fpc fp-units-fcl fp-units-net tzdata curl jq \
|
||||||
libssl3 libssl-dev \
|
libssl3 libssl-dev cron \
|
||||||
&& apt-get clean && rm -rf /var/lib/apt/lists/*
|
&& apt-get clean && rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
WORKDIR /app
|
WORKDIR /app
|
||||||
COPY statusbot.pas .
|
|
||||||
|
|
||||||
# Fordítás
|
COPY statusbot.pas .
|
||||||
RUN fpc statusbot.pas
|
RUN fpc statusbot.pas
|
||||||
|
|
||||||
# Cron telepítése
|
|
||||||
RUN apt-get update && apt-get install -y cron && apt-get clean && rm -rf /var/lib/apt/lists/*
|
|
||||||
|
|
||||||
# Cron fájl másolása
|
|
||||||
COPY cronjob /etc/cron.d/discord-cron
|
COPY cronjob /etc/cron.d/discord-cron
|
||||||
RUN chmod 0644 /etc/cron.d/discord-cron && crontab /etc/cron.d/discord-cron
|
RUN chmod 0644 /etc/cron.d/discord-cron
|
||||||
|
|
||||||
# Konténer mindig fusson, cron háttérben
|
CMD ["cron", "-f"]
|
||||||
CMD ["cron", "-f"]
|
|
||||||
|
|||||||
Reference in New Issue
Block a user