Module: check_mk
Branch: master
Commit: 58f351de2cefea6dc3be0c4e585d606ceb758dca
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=58f351de2cefea…
Author: Simon Betz <si(a)mathias-kettner.de>
Date: Thu Dec 20 11:20:24 2018 +0100
agent_aws: Adapted help text of region option
Change-Id: Icc1e0618af271505062a2bd7db28d4183cc9b1a6
---
agents/special/agent_aws | 41 ++++++++++++++++++++++-------------------
1 file changed, 22 insertions(+), 19 deletions(-)
diff --git a/agents/special/agent_aws b/agents/special/agent_aws
index 648958d..8e6ee05 100755
--- a/agents/special/agent_aws
+++ b/agents/special/agent_aws
@@ -958,6 +958,27 @@ class AWSSections(object):
# | |
# '----------------------------------------------------------------------'
+AWSRegions = [
+ ("ap-south-1", "Asia Pacific (Mumbai)"),
+ ("ap-northeast-3", "Asia Pacific (Osaka-Local)"),
+ ("ap-northeast-2", "Asia Pacific (Seoul)"),
+ ("ap-southeast-1", "Asia Pacific (Singapore)"),
+ ("ap-southeast-2", "Asia Pacific (Sydney)"),
+ ("ap-northeast-1", "Asia Pacific (Tokyo)"),
+ ("ca-central-1", "Canada (Central)"),
+ ("cn-north-1", "China (Beijing)"),
+ ("cn-northwest-1", "China (Ningxia)"),
+ ("eu-central-1", "EU (Frankfurt)"),
+ ("eu-west-1", "EU (Ireland)"),
+ ("eu-west-2", "EU (London)"),
+ ("eu-west-3", "EU (Paris)"),
+ ("sa-east-1", "South America (Sao Paulo)"),
+ ("us-east-2", "US East (Ohio)"),
+ ("us-east-1", "US East (N. Virginia)"),
+ ("us-west-1", "US West (N. California)"),
+ ("us-west-2", "US West (Oregon)"),
+]
+
def parse_arguments(argv):
parser = argparse.ArgumentParser(
@@ -970,25 +991,7 @@ def parse_arguments(argv):
parser.add_argument(
"--region",
required=True,
- help="""The region to use:
-ap-south-1 Asia Pacific (Mumbai)
-ap-northeast-3 Asia Pacific (Osaka-Local)
-ap-northeast-2 Asia Pacific (Seoul)
-ap-southeast-1 Asia Pacific (Singapore)
-ap-southeast-2 Asia Pacific (Sydney)
-ap-northeast-1 Asia Pacific (Tokyo)
-ca-central-1 Canada (Central)
-cn-north-1 China (Beijing)
-cn-northwest-1 China (Ningxia)
-eu-central-1 EU (Frankfurt)
-eu-west-1 EU (Ireland)
-eu-west-2 EU (London)
-eu-west-3 EU (Paris)
-sa-east-1 South America (Sao Paulo)
-us-east-2 US East (Ohio)
-us-east-1 US East (N. Virginia)
-us-west-1 US West (N. California)
-us-west-2 US West (Oregon)""")
+ help="The region to use:\n%s" % "\n".join(["%-15s
%s" % e for e in AWSRegions]))
parser.add_argument(
"--no-cache", action="store_true", help="Execute all
sections, do not rely on cached data.")
parser.add_argument("hostname")