mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2026-03-22 03:17:43 -02:30
Update inventory.py
This commit is contained in:
@@ -86,8 +86,12 @@ class KargoInventory(object):
|
|||||||
self.write_config(self.config_file)
|
self.write_config(self.config_file)
|
||||||
|
|
||||||
def write_config(self, config_file):
|
def write_config(self, config_file):
|
||||||
with open(config_file, 'w') as f:
|
if config_file:
|
||||||
self.config.write(f)
|
with open(config_file, 'w') as f:
|
||||||
|
self.config.write(f)
|
||||||
|
else:
|
||||||
|
print("WARNING: Unable to save config. Make sure you set "
|
||||||
|
"CONFIG_FILE env var.")
|
||||||
|
|
||||||
def debug(self, msg):
|
def debug(self, msg):
|
||||||
if DEBUG:
|
if DEBUG:
|
||||||
|
|||||||
Reference in New Issue
Block a user