mirror of
https://github.com/hyperknot/openfreemap.git
synced 2026-05-21 14:02:15 +00:00
logging fixes
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
#!/usr/bin/env python3
|
||||
from datetime import datetime, timezone
|
||||
|
||||
import click
|
||||
from http_host_lib.assets import (
|
||||
@@ -14,6 +15,9 @@ from http_host_lib.sync import auto_clean_btrfs, full_sync
|
||||
from http_host_lib.versions import fetch_version_files
|
||||
|
||||
|
||||
now = datetime.now(timezone.utc)
|
||||
|
||||
|
||||
@click.group()
|
||||
def cli():
|
||||
"""
|
||||
@@ -96,6 +100,8 @@ def sync(force):
|
||||
On a new server this also takes care of everything, no need to run anything manually.
|
||||
"""
|
||||
|
||||
print(f'---\n{now}\nrunning full_sync')
|
||||
|
||||
full_sync(force)
|
||||
|
||||
|
||||
|
||||
@@ -16,10 +16,6 @@ def full_sync(force=False):
|
||||
On a new server this also takes care of everything, no need to run anything manually.
|
||||
"""
|
||||
|
||||
print('---')
|
||||
print('running full_sync')
|
||||
print(datetime.now(timezone.utc))
|
||||
|
||||
assert_linux()
|
||||
assert_sudo()
|
||||
|
||||
|
||||
@@ -69,7 +69,7 @@ def set_version(area, version):
|
||||
Set versions for a given area
|
||||
"""
|
||||
|
||||
print(f'{now} starting set-version {area}')
|
||||
print(f'---\n{now}\nstarting set-version {area}')
|
||||
|
||||
check_and_set_version(area, version)
|
||||
|
||||
|
||||
@@ -12,7 +12,7 @@ def check_and_set_version(area, version):
|
||||
return
|
||||
|
||||
version = versions[-1]
|
||||
print(f'---\nLatest version on bucket: {area} {version}')
|
||||
print(f' Latest version on bucket: {area} {version}')
|
||||
|
||||
if not check_all_hosts(area, version):
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user