mirror of https://git.48k.eu/ogclient
utils: consolidate logging to write checksum file to cache
Move log message to function that is called both by unicast and tiptorrent.master
parent
8ac8dc306e
commit
59ab9204ce
|
@ -50,6 +50,9 @@ def tip_write_csum(image_name):
|
|||
if not os.path.exists(image_path):
|
||||
raise OgError(f'Invalid image path {image_path} for tiptorrent checksum writing')
|
||||
|
||||
logging.info('Calculating checksum...')
|
||||
logging.info('*DO NOT REBOOT OR POWEROFF* the client during this time')
|
||||
|
||||
filename = image_path + ".full.sum"
|
||||
csum = _compute_md5(image_path)
|
||||
try:
|
||||
|
@ -106,6 +109,4 @@ def tip_client_get(tip_addr, image_name):
|
|||
if proc.returncode != 0:
|
||||
raise OgError(f'Error fetching image {image_name} via tiptorrent')
|
||||
else:
|
||||
logging.info('Calculating checksum...')
|
||||
logging.info('*DO NOT REBOOT OR POWEROFF* the client during this time')
|
||||
tip_write_csum(image_name)
|
||||
|
|
Loading…
Reference in New Issue