Skip to content

Commit

Permalink
stop excess docker pulls
Browse files Browse the repository at this point in the history
  • Loading branch information
Roy Wiggins authored and Roy Wiggins committed Apr 12, 2024
1 parent 93f5a40 commit c13a198
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion process/process_series.py
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,9 @@ def decode_task_json(json_string: Optional[str]) -> Any:
# In lieu of making mercure a sudoer...
logger.debug("Changing the ownership of the output directory...")
try:
docker_client.images.pull("busybox:stable-musl")
if (datetime.now() - docker_pull_throttle.get("busybox:stable-musl",datetime.fromisocalendar(1,1,1))).total_seconds() > 86400:
docker_client.images.pull("busybox:stable-musl")
docker_pull_throttle["busybox:stable_musl"] = datetime.now()
except:
logger.exception("could not pull busybox")

Expand Down

0 comments on commit c13a198

Please sign in to comment.