update
continuous-integration/drone/push Build is passing Details

master
Enzo 2 years ago
parent de23e4785d
commit 011f04d145

@ -8,8 +8,10 @@ COPY generateurModele.py .
COPY testFinal.py . COPY testFinal.py .
COPY crontab . COPY crontab .
RUN touch /app/cron.log
RUN chmod 0644 /app/crontab RUN chmod 0644 /app/crontab
RUN apt-get update RUN apt-get update
RUN apt-get -y install cron RUN apt-get -y install cron
ENTRYPOINT ["cron"] CMD cron && tail -f /app/cron.log

@ -1,3 +1,3 @@
00 08 * * * python generateurModele.py * * * * * python testFinal.py >> /app/cron.log 2>&1
* * * * * python testFinal.py 00 08 * * * python generateurModele.py >> /app/cron.log 2>&1

@ -54,8 +54,8 @@ def sendJsonToApi(url,json):
return return
# ---------------- Main ------------------- # # ---------------- Main ------------------- #
# Mettre la route de l'api ICI logging.error("RUNNNNNNNN !")
urlGetAllData = "https://codefirst.iut.uca.fr/containers/SmartFit-smartfit_api/IA" urlGetAllData = "https://codefirst.iut.uca.fr/containers/SmartFit-smartfit_api/ia/data"
while(True): while(True):
logging.warning("Info - Début de la boucle") logging.warning("Info - Début de la boucle")
jsonBack = { "Users" : []} jsonBack = { "Users" : []}

@ -53,7 +53,7 @@ def sendJsonToApi(url,json):
return return
# ---------------- Main ------------------- # # ---------------- Main ------------------- #
logging.warning("RUNNNNNNNN !") logging.error("RUNNNNNNNN !")
urlGetAllData = "https://codefirst.iut.uca.fr/containers/SmartFit-smartfit_api/ia/data" urlGetAllData = "https://codefirst.iut.uca.fr/containers/SmartFit-smartfit_api/ia/data"

Loading…
Cancel
Save