??????????????
Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 173
Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 174
Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 175
Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 176
Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 177
Warning: Cannot modify header information - headers already sent by (output started at /home/mybf1/public_html/mentol.bf1.my/SS1.php:4) in /home/mybf1/public_html/mentol.bf1.my/SS1.php on line 178
Udac @` s d d l m Z m Z m Z e Z d Z d Z d Z d d l m
Z
y d d l Z d d l Z Wn e
k
r e
d n Xd d l m Z d d l m Z d d
l m Z d Z d e f d
YZ d S( i ( t absolute_importt divisiont print_functions
lookup: aws_secret
author:
- Aaron Smith
version_added: "2.8"
requirements:
- boto3
- botocore>=1.10.0
extends_documentation_fragment:
- aws_credentials
- aws_region
short_description: Look up secrets stored in AWS Secrets Manager.
description:
- Look up secrets stored in AWS Secrets Manager provided the caller
has the appropriate permissions to read the secret.
- Lookup is based on the secret's `Name` value.
- Optional parameters can be passed into this lookup; `version_id` and `version_stage`
options:
_terms:
description: Name of the secret to look up in AWS Secrets Manager.
required: True
version_id:
description: Version of the secret(s).
required: False
version_stage:
description: Stage of the secret version.
required: False
join:
description:
- Join two or more entries to form an extended secret.
- This is useful for overcoming the 4096 character limit imposed by AWS.
type: boolean
default: false
s:
- name: Create RDS instance with aws_secret lookup for password param
rds:
command: create
instance_name: app-db
db_engine: MySQL
size: 10
instance_type: db.m1.small
username: dbadmin
password: "{{ lookup('aws_secret', 'DbSecret') }}"
tags:
Environment: staging
sY
_raw:
description:
Returns the value of the secret stored in AWS Secrets Manager.
( t AnsibleErrorNs2 The lookup aws_secret requires boto3 and botocore.( t
AnsiblePlugin( t
LookupBase( t to_nativec C` s | j d d } y( t j j d | j d | | } Wn t j j t j j f k
r } | r y% t j j d | j d | } Wq t j j t j j f k
r } t
d q Xq t
d n X| S( Nt aws_profilet profile_namet secretsmanagers Insufficient credentials found.( t popt Nonet boto3t sessiont Sessiont clientt botocoret
exceptionst ProfileNotFoundt PartialCredentialsErrorR ( t regiont credentialst boto_profilet
connectiont e( ( sE /usr/lib/python2.7/site-packages/ansible/plugins/lookup/aws_secret.pyt _boto3_connK s (!%!t LookupModulec B` s e Z d Z d Z RS( c C` s i } | j d | d <| j d | d <| j d | d <| j d | d <| d r | d on | d r t j j } | j d k r | j j | d <| j j | d <| j j | d