summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPaul C. Buetow <paul@buetow.org>2014-04-16 08:26:44 +0200
committerPaul C. Buetow <paul@buetow.org>2014-04-16 08:26:44 +0200
commit3666d7d9d08d6c79017f57085ca8270961bafde9 (patch)
treef48ec3021d5b8a04b1ad81356b88952d1bfa8031 /src
parent9f201d6b32a1c97a4e70f955b4ccd8b0b1ead1c5 (diff)
Fine day to work off excess energy. Steal something heavy.
Diffstat (limited to 'src')
-rwxr-xr-xsrc/fapi9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/fapi b/src/fapi
index 3b02caf..9a4dd9f 100755
--- a/src/fapi
+++ b/src/fapi
@@ -88,12 +88,8 @@ class Fapi(object):
password = getpass.getpass(prompt)
self.info('Login to BigIP API with user %s' % username)
- if a.e != None:
- loadbalancers = c.get('fapi', 'loadbalancers_' + a.e)
- else:
- loadbalancers = c.get('fapi', 'loadbalancers')
-
# Try a comma separated lists of F5 boxes, use the first one
+ loadbalancers = c.get('fapi', 'loadbalancers_' + a.e)
err = None
for loadbalancer in loadbalancers.split(','):
try:
@@ -442,7 +438,8 @@ if __name__ == '__main__':
''' The main function, here we will have Popcorn for free! '''
parser = argparse.ArgumentParser(add_help=False)
- parser.add_argument('-e', action='store', help='Env to use, e.g. dev,qa,live')
+ parser.add_argument('-e', action='store', help='Env to use, e.g. dev,qa,live',
+ default='qa')
parser.add_argument('-h', action='store_true', help='Help')
parser.add_argument('-p', action='store', help='Overwrite partition from fapi.conf')
parser.add_argument('-v', action='store_true', help='Verbose')