From 11e416995a70dbccd8f0a3e9c8be3c9bd79b538b Mon Sep 17 00:00:00 2001 From: Elijah DeLee Date: Mon, 21 Jun 2021 07:51:00 -0400 Subject: [PATCH] accept old env vars this broke our build of the cli docs --- awxkit/awxkit/cli/sphinx.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/awxkit/awxkit/cli/sphinx.py b/awxkit/awxkit/cli/sphinx.py index 47366898d3..bb5e36ce76 100644 --- a/awxkit/awxkit/cli/sphinx.py +++ b/awxkit/awxkit/cli/sphinx.py @@ -43,9 +43,13 @@ def render(): # The return value of this function is an argparse.ArgumentParser, which # the sphinxcontrib.autoprogram plugin crawls and generates an indexed # Sphinx document from. - for e in ('CONTROLLER_HOST', 'CONTROLLER_USERNAME', 'CONTROLLER_PASSWORD'): - if not os.environ.get(e): - raise SystemExit('Please specify a valid {} for a real (running) installation.'.format(e)) # noqa + for e in ( + ('CONTROLLER_HOST', 'TOWER_HOST'), + ('CONTROLLER_USERNAME', 'TOWER_USERNAME'), + ('CONTROLLER_PASSWORD', 'TOWER_PASSWORD'), + ): + if not os.environ.get(e[0]) and not os.environ.get(e[1]): + raise SystemExit('Please specify a valid {} for a real (running) installation.'.format(e[0])) # noqa cli = CLI() cli.parse_args(['awx', '--help']) cli.connect()