Wallah ça marche mtn
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
d665c3a2af
commit
f10942a1ee
@ -1,33 +1,12 @@
|
||||
FROM python:3.10
|
||||
|
||||
EXPOSE 80
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Copier les fichiers nécessaires dans l'image
|
||||
COPY requirements.txt .
|
||||
COPY generateurModele.py .
|
||||
COPY testFinal.py .
|
||||
COPY crontab .
|
||||
|
||||
# Installer les dépendances
|
||||
RUN pip install -r requirements.txt
|
||||
|
||||
# Créer le fichier de log
|
||||
RUN touch /app/cron.log
|
||||
|
||||
# Donner les permissions nécessaires
|
||||
RUN chmod 777 /app/crontab
|
||||
|
||||
# Installer le service cron
|
||||
COPY . .
|
||||
# Cron
|
||||
RUN apt-get update && apt-get -y install cron
|
||||
|
||||
# Copier le script d'entrée
|
||||
#COPY entrypoint.sh /app/entrypoint.sh
|
||||
#RUN chmod +x /app/entrypoint.sh
|
||||
|
||||
RUN chmod 0644 /app/crontab
|
||||
RUN crontab /app/crontab
|
||||
RUN crontab -l
|
||||
|
||||
# Définir le point d'entrée de l'image
|
||||
ENTRYPOINT ["service","cron","restart"]
|
||||
# Python
|
||||
RUN pip install -r requirements.txt
|
||||
ENTRYPOINT ["cron","-f"]
|
||||
|
@ -1,3 +1,2 @@
|
||||
* * * * * python3 /app/testFinal.py
|
||||
00 08 * * * python3 /app/generateurModele.py
|
||||
*/1 * * * * python3 /app/generateurModele.py
|
||||
|
||||
|
Loading…
Reference in new issue