Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
saturn committed Feb 6, 2024
1 parent 99146b7 commit 8fcec14
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion examples/registering-images/register.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ def delete_all_tags(saturn_image_id: str, tags: List[Dict], dry_run: bool=False)
url = make_url(f"api/images/{saturn_image_id}/tags/{t['id']}")
print('delete', url)
if not dry_run:
requests.delete(url, headers=saturn_headers).json()
resp = requests.delete(url, headers=saturn_headers)


def register_by_id(image_uri: str, version: str, saturn_image_id: str, dry_run: bool = False):
Expand Down Expand Up @@ -169,12 +169,14 @@ def cli():
@cli.command()
def run_once():
sync()
sync_base()


@cli.command()
def run():
while True:
sync()
sync_base()
time.sleep(30)


Expand Down

0 comments on commit 8fcec14

Please sign in to comment.