add MODEL_NAME variable to determine model
This commit is contained in:
+5
-2
@@ -51,8 +51,11 @@ def get_juju_model():
|
||||
# Check the environment
|
||||
CURRENT_MODEL = os.environ["JUJU_MODEL"]
|
||||
except KeyError:
|
||||
# If unset connect get the current active model
|
||||
CURRENT_MODEL = get_current_model()
|
||||
try:
|
||||
CURRENT_MODEL = os.environ["MODEL_NAME"]:
|
||||
except KeyError:
|
||||
# If unset connect get the current active model
|
||||
CURRENT_MODEL = get_current_model()
|
||||
return CURRENT_MODEL
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user