From 6b1b61f98813a58286e099d92767e01c2d40bc18 Mon Sep 17 00:00:00 2001 From: LMBishop <13875753+LMBishop@users.noreply.github.com> Date: Sun, 20 Nov 2022 20:33:13 +0000 Subject: Redo deploy script --- util/helpers.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 util/helpers.py (limited to 'util/helpers.py') diff --git a/util/helpers.py b/util/helpers.py new file mode 100644 index 0000000..5f970df --- /dev/null +++ b/util/helpers.py @@ -0,0 +1,13 @@ +import os + +OS_TYPE = os.getenv("OS_TYPE") + + +# Returns True if all preconditions pass +def check_preconditions(obj): + if "preconditions" in obj: + if ("os" in obj["preconditions"] + and obj["preconditions"]["os"] != OS_TYPE): + return False + + return True -- cgit v1.2.3-70-g09d2