Skip to content

Commit

Permalink
#12: Fix the AttributeError exception
Browse files Browse the repository at this point in the history
  • Loading branch information
tlex committed Oct 26, 2023
1 parent a105046 commit 61fd587
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cioban/cioban.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
""" A docker swarm service for automatically updating your services to the latest image tag push. """

import logging
from datetime import datetime
from datetime import datetime, timedelta
import requests
import pause
import docker
Expand Down Expand Up @@ -111,7 +111,7 @@ def __set_timer(self):
self.sleep_type = 'seconds'
cron_timer = CronSim(self.settings['schedule_time'], datetime.now())
self.sleep = (next(cron_timer) - datetime.now()).seconds + 1
next_run = str(datetime.timedelta(seconds = self.sleep))
next_run = str(timedelta(seconds = self.sleep))
log.debug(f"Based on the cron schedule '{self.settings['schedule_time']}', next run is in {next_run}")

def __get_updated_image(self, image, image_sha):
Expand Down

0 comments on commit 61fd587

Please sign in to comment.