mirror of
https://bitbucket.org/atlassian/dc-deployments-automation.git
synced 2025-12-13 16:33:08 -06:00
DCD-224: Move EC2 metadata retrieval to aws_common
This commit is contained in:
@@ -8,5 +8,5 @@
|
||||
** This is where env-vars should be converted to Ansible vars. It also acts as a required-env list.
|
||||
** The CF env is usually stored in /etc/atl. The script `bin/ansible-with-atl-env` will run Ansible with that environment set.
|
||||
* Runtime information about the EC2 environment can be injected by depending on
|
||||
`aws_metadata` in a role's `meta/main.yml`.
|
||||
|
||||
`aws_common` in a role's `meta/main.yml` (or adding it to the playbook before
|
||||
the requiring role.
|
||||
|
||||
@@ -6,3 +6,8 @@
|
||||
- ec2-utils
|
||||
- amazon-ssm-agent
|
||||
- amazon-efs-utils
|
||||
|
||||
- name: Fetch local EC2 metadata
|
||||
ec2_metadata_facts:
|
||||
# Guard is mostly for testing
|
||||
when: ansible_system_vendor == "Amazon EC2"
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
---
|
||||
dependencies:
|
||||
- aws_metadata
|
||||
- aws_common
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
file:
|
||||
state: directory
|
||||
path: "{{ atl_shared_mountpoint }}"
|
||||
owner: "{{ product_user }}"
|
||||
owner: "{{ atl_product_user }}"
|
||||
mode: 0755
|
||||
|
||||
- name: Enable mountpoint in fstab
|
||||
|
||||
@@ -1,7 +0,0 @@
|
||||
---
|
||||
|
||||
# This role is primarily intended to be depended on via `meta` by
|
||||
# roles that need runtime information available.
|
||||
|
||||
- name: Fetch local EC2 metadata
|
||||
ec2_metadata_facts:
|
||||
Reference in New Issue
Block a user