Browse Source

try the schedule library (container problem)

marton levente 11 months ago
parent
commit
da891774dd
1 changed files with 15 additions and 0 deletions
  1. 15 0
      scheduled.py

+ 15 - 0
scheduled.py

@@ -0,0 +1,15 @@
+'''Created 3 Oct 2023 Levi'''
+import time
+import schedule
+
+import mail_alert
+
+schedule.every(5).seconds.do(mail_alert.mail_alert)
+schedule.every(5).seconds.do(mail_alert.mail_alert2)
+schedule.every(5).seconds.do(mail_alert.mail_alert3)
+
+
+if __name__ == '__main__':
+    while True:
+        schedule.run_pending()
+        time.sleep(1)