Just use CLOUD_NAMES as env variable

CLOUD_NAMES vs CLOUD_NAME is a one character difference which may
be easily overlooked.  The split method will work even with only
one item and no ','.  And in Zuul we already have the convention
of describing an input that accepts one or more items with a plural
noun.

Change-Id: I28b8b6be2b536d627bf77665b5c3e583000efbda
This commit is contained in:
James E. Blair 2021-02-11 10:07:04 -08:00
parent 6a0e496a5b
commit 8f35ff5f0f

View File

@ -186,9 +186,6 @@ class CloudCache(object):
self.log = logging.getLogger('middleware') self.log = logging.getLogger('middleware')
self.app = app self.app = app
if 'CLOUD_NAME' in os.environ:
cloud_names = [os.environ['CLOUD_NAME']]
else:
cloud_names = os.environ['CLOUD_NAMES'].split(',') cloud_names = os.environ['CLOUD_NAMES'].split(',')
self.clouds = [] self.clouds = []