Fix container and add dry run ability.

This commit is contained in:
James Grogan 2024-03-29 12:18:29 +00:00
parent d1b91a0a89
commit 43114d8c1f
4 changed files with 14 additions and 2 deletions

View file

@ -1,4 +1,13 @@
import subprocess
import logging
_DRY_RUN = False
def set_is_dry_run(is_dry_run: bool):
_DRY_RUN = is_dry_run
def run_op(op: str):
return subprocess.run(op, shell=True)
if _DRY_RUN:
return subprocess.run(op, shell=True)
else:
logging.info(f"Dry Run | {op}")