summaryrefslogtreecommitdiffstats
path: root/lib/python/apex-python-utils.py
diff options
context:
space:
mode:
Diffstat (limited to 'lib/python/apex-python-utils.py')
-rwxr-xr-xlib/python/apex-python-utils.py11
1 files changed, 10 insertions, 1 deletions
diff --git a/lib/python/apex-python-utils.py b/lib/python/apex-python-utils.py
index 1d5b4a7c..7e947ea6 100755
--- a/lib/python/apex-python-utils.py
+++ b/lib/python/apex-python-utils.py
@@ -7,7 +7,6 @@
# http://www.apache.org/licenses/LICENSE-2.0
##############################################################################
-
import argparse
import sys
import apex
@@ -21,6 +20,10 @@ def parse_net_settings(settings_args):
settings_args.network_isolation)
settings.dump_bash()
+def parse_deploy_settings(settings_args):
+ settings = apex.DeploySettings(settings_args.path)
+ settings.dump_bash()
+
def find_ip(int_args):
interface = apex.ip_utils.get_interface(int_args.interface,
@@ -73,6 +76,12 @@ nic_template.add_argument('-af', '--address_family', type=int, default=4,
help='IP address family')
nic_template.set_defaults(func=build_nic_template)
+deploy_settings = subparsers.add_parser('parse-deploy-settings',
+ help='Parse deploy settings file')
+deploy_settings.add_argument('-f', '--path', default='deploy_settings.yaml',
+ help='path to deploy settings file')
+deploy_settings.set_defaults(func=parse_deploy_settings)
+
args = parser.parse_args(sys.argv[1:])
if args.DEBUG:
logging.basicConfig(level=logging.DEBUG)