Esempio n. 1
0
 def compare_certs(self):
     logger.info("Going to check env certs")
     parser = argparse.ArgumentParser(description='ec2 tool for devops', usage='''kerrigan.py iam compare_certs [<args>]]
     ''' + self.global_options)
     parser.add_argument('--env', action='store', help="Envs to check")
     args = parser.parse_args(sys.argv[3:])
     a = awschecks()
     a.compare_certs(env=args.env)
Esempio n. 2
0
 def compare(self):
     logger.info("Starting to gather information")
     parser = argparse.ArgumentParser(description='ec2 tool for devops', usage='''kerrigan.py s3 compare [<args>]]
     ''' + self.global_options)
     parser.add_argument('--env', action='store', help="Name of env")
     args = parser.parse_args(sys.argv[3:])
     c = awschecks()
     c.compare_s3(env=args.env)
Esempio n. 3
0
 def compare(self):
     logger.info("Creating ELB")
     parser = argparse.ArgumentParser(description='ec2 tool for devops', usage='''kerrigan.py elb create [<args>]]
     ''' + self.global_options)
     parser.add_argument('--env', action='store', help="Which env to check")
     args = parser.parse_args(sys.argv[3:])
     c = awschecks()
     c.compare_elb(env=args.env)
Esempio n. 4
0
 def sync_instances(self):
     logger.info("Syncing Instances to ELB")
     parser = argparse.ArgumentParser(description='ec2 tool for devops', usage='''kerrigan.py elb sync_instances [<args>]]
     ''' + self.global_options)
     parser.add_argument('--env', action='store', help="Which env to check")
     parser.add_argument('--dryrun', action='store_true',default=False, help="No changes should be done")
     args = parser.parse_args(sys.argv[3:])
     c = awschecks()
     c.sync_instances_to_elbs(env=args.env,dryrun=args.dryrun)
Esempio n. 5
0
 def compare_iam(self):
     logger.info("Going to check env iam certificates")
     parser = argparse.ArgumentParser(description='ec2 tool for devops', usage='''kerrigan.py iam compare_iam [<args>]]
     ''' + self.global_options)
     parser.add_argument('--env', action='store', help="Envs to check")
     parser.add_argument('--dryrun', action='store_true', default=False, help="No changes should be done")
     args = parser.parse_args(sys.argv[3:])
     a = awschecks()
     a.compare_iam(env=args.env, dryrun=args.dryrun)
Esempio n. 6
0
 def compare(self):
     logger.info("Starting comparing route53 entries")
     parser = argparse.ArgumentParser(description='ec2 tool for devops', usage='''kerrigan.py route53 compare [<args>]]
     ''' + self.global_options)
     parser.add_argument('--env', action='store', help="Environment to gather information about")
     parser.add_argument('--dryrun', action='store_true',default=False, help="No changes should be done")
     args = parser.parse_args(sys.argv[3:])
     a = awschecks()
     a.compare_route53(env=args.env,dryrun=args.dryrun)
Esempio n. 7
0
 def compare(self):
     logger.info("Starting to gather information")
     parser = argparse.ArgumentParser(
         description='ec2 tool for devops',
         usage='''kerrigan.py s3 compare [<args>]]
     ''' + self.global_options)
     parser.add_argument('--env', action='store', help="Name of env")
     args = parser.parse_args(sys.argv[3:])
     c = awschecks()
     c.compare_s3(env=args.env)
Esempio n. 8
0
 def compare(self):
     logger.info("Creating ELB")
     parser = argparse.ArgumentParser(
         description='ec2 tool for devops',
         usage='''kerrigan.py elb create [<args>]]
     ''' + self.global_options)
     parser.add_argument('--env', action='store', help="Which env to check")
     args = parser.parse_args(sys.argv[3:])
     c = awschecks()
     c.compare_elb(env=args.env)
Esempio n. 9
0
 def compare(self):
     logger.info("Going to compare security groups")
     a = awsrequests()
     parser = argparse.ArgumentParser(description='ec2 tool for devops', usage='''kerrigan.py instance compare_securitygroups [<args>]]
     ''' + self.global_options)
     parser.add_argument('--env', action='store', help="Environment to check")
     parser.add_argument('--dryrun', action='store_true', default=False, help="No actions should be taken")
     args = parser.parse_args(sys.argv[3:])
     a = awschecks()
     a.compare_securitygroups(env=args.env, dryrun=args.dryrun)
Esempio n. 10
0
 def sync_instances(self):
     logger.info("Syncing Instances to ELB")
     parser = argparse.ArgumentParser(
         description='ec2 tool for devops',
         usage='''kerrigan.py elb sync_instances [<args>]]
     ''' + self.global_options)
     parser.add_argument('--env', action='store', help="Which env to check")
     parser.add_argument('--dryrun',
                         action='store_true',
                         default=False,
                         help="No changes should be done")
     args = parser.parse_args(sys.argv[3:])
     c = awschecks()
     c.sync_instances_to_elbs(env=args.env, dryrun=args.dryrun)
Esempio n. 11
0
 def compare(self):
     logger.info("Starting comparing route53 entries")
     parser = argparse.ArgumentParser(
         description='ec2 tool for devops',
         usage='''kerrigan.py route53 compare [<args>]]
     ''' + self.global_options)
     parser.add_argument('--env',
                         action='store',
                         help="Environment to gather information about")
     parser.add_argument('--dryrun',
                         action='store_true',
                         default=False,
                         help="No changes should be done")
     args = parser.parse_args(sys.argv[3:])
     a = awschecks()
     a.compare_route53(env=args.env, dryrun=args.dryrun)
Esempio n. 12
0
 def compare(self):
     logger.info("Going to compare security groups")
     a = awsrequests()
     parser = argparse.ArgumentParser(
         description='ec2 tool for devops',
         usage='''kerrigan.py instance compare_securitygroups [<args>]]
     ''' + self.global_options)
     parser.add_argument('--env',
                         action='store',
                         help="Environment to check")
     parser.add_argument('--dryrun',
                         action='store_true',
                         default=False,
                         help="No actions should be taken")
     args = parser.parse_args(sys.argv[3:])
     a = awschecks()
     a.compare_securitygroups(env=args.env, dryrun=args.dryrun)
Esempio n. 13
0
 def gw_watchdog(self, env=None):
     logger.debug("Starting gw watchdog service")
     envs = super(awsservice, self).get_needed_envs(env=env)
     a = awschecks()
     for env in envs:
         a.check_gws_in_env(env=env)