mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-06 21:32:49 +00:00
AWS: _facts -> _info (part 2) (#57626)
* Rename cloudwatchlogs_log_group_facts -> cloudwatchlogs_log_group_info. * Rename elasticache_facts -> elasticache_info. * redshift_facts -> redshift_info. * Rename route53_facts -> route53_info. * Rename rds_instance_facts -> rds_instance_info. * Rename rds_snapshot_facts -> rds_snapshot_info. * Rename iam_mfa_device_facts -> iam_mfa_device_info. * Rename iam_role_facts -> iam_role_info. * Rename iam_server_certificate_facts -> iam_server_certificate_info. * Rename elb_application_lb_facts -> elb_application_lb_info. * Renaming elb_classic_lb_facts -> elb_classic_lb_info. * elb_target_facts -> elb_target_info. * Rename elb_target_group_facts -> elb_target_group_info. * Update porting guide. * Add changelog. * Fix module defaults (both for this PR and #57613). * Two fixes.
This commit is contained in:
@@ -26,18 +26,18 @@
|
||||
register: iam_role_output
|
||||
ignore_errors: yes
|
||||
|
||||
# CI does not remove the role and comparing policies has a bug on Python3; fall back to use iam_role_facts
|
||||
# CI does not remove the role and comparing policies has a bug on Python3; fall back to use iam_role_info
|
||||
- name: get IAM role
|
||||
iam_role_facts:
|
||||
iam_role_info:
|
||||
<<: *aws_connection_info
|
||||
name: "test-secrets-manager-role"
|
||||
when: iam_role_output is failed
|
||||
register: iam_role_facts
|
||||
register: iam_role_info
|
||||
|
||||
- name: set iam_role_output
|
||||
set_fact:
|
||||
iam_role_output: "{{ iam_role_facts.iam_roles[0] }}"
|
||||
when: iam_role_facts is defined
|
||||
iam_role_output: "{{ iam_role_info.iam_roles[0] }}"
|
||||
when: iam_role_info is defined
|
||||
|
||||
- name: create a temporary directory
|
||||
tempfile:
|
||||
|
||||
@@ -85,7 +85,7 @@
|
||||
register: lock_attempt_log_group_result
|
||||
|
||||
- name: Get Lock Attempt Lock Groups
|
||||
cloudwatchlogs_log_group_facts:
|
||||
cloudwatchlogs_log_group_info:
|
||||
log_group_name: "{{ lock_log_group_prefix }}/"
|
||||
<<: *aws_connection_info
|
||||
register: lock_attempt_log_groups
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
<<: *aws_connection_info
|
||||
|
||||
- name: ensure AWSServiceRoleForECS role exists
|
||||
iam_role_facts:
|
||||
iam_role_info:
|
||||
name: AWSServiceRoleForECS
|
||||
<<: *aws_connection_info
|
||||
register: iam_role_result
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
environment: "{{ ansible_test.environment }}"
|
||||
|
||||
roles:
|
||||
- elb_target_facts
|
||||
- elb_target_info
|
||||
@@ -1,10 +1,10 @@
|
||||
---
|
||||
- name: set up elb_target_facts test prerequisites
|
||||
- name: set up elb_target_info test prerequisites
|
||||
|
||||
block:
|
||||
|
||||
- name:
|
||||
debug: msg="********** Setting up elb_target_facts test dependencies **********"
|
||||
debug: msg="********** Setting up elb_target_info test dependencies **********"
|
||||
# ============================================================
|
||||
|
||||
- name: set up aws connection info
|
||||
@@ -213,11 +213,11 @@
|
||||
|
||||
# ============================================================
|
||||
|
||||
- debug: msg="********** Running elb_target_facts integration tests **********"
|
||||
- debug: msg="********** Running elb_target_info integration tests **********"
|
||||
|
||||
# ============================================================
|
||||
- name: gather facts
|
||||
elb_target_facts:
|
||||
elb_target_info:
|
||||
instance_id: "{{ ec2.instance_ids[0]}}"
|
||||
<<: *aws_connection_info
|
||||
register: target_facts
|
||||
@@ -240,7 +240,7 @@
|
||||
<<: *aws_connection_info
|
||||
|
||||
- name: gather facts again, including the idle group
|
||||
elb_target_facts:
|
||||
elb_target_info:
|
||||
instance_id: "{{ ec2.instance_ids[0]}}"
|
||||
<<: *aws_connection_info
|
||||
register: target_facts
|
||||
@@ -254,7 +254,7 @@
|
||||
msg: "target facts reflected the addition of the target to the idle group"
|
||||
|
||||
- name: gather facts again, this time excluding the idle group
|
||||
elb_target_facts:
|
||||
elb_target_info:
|
||||
instance_id: "{{ ec2.instance_ids[0]}}"
|
||||
get_unused_target_groups: false
|
||||
<<: *aws_connection_info
|
||||
@@ -279,7 +279,7 @@
|
||||
<<: *aws_connection_info
|
||||
|
||||
- name: gather facts
|
||||
elb_target_facts:
|
||||
elb_target_info:
|
||||
instance_id: "{{ ec2.instance_ids[0] }}"
|
||||
get_unused_target_groups: false
|
||||
<<: *aws_connection_info
|
||||
@@ -315,7 +315,7 @@
|
||||
- "targets"
|
||||
|
||||
- name: wait for all targets to deregister simultaneously
|
||||
elb_target_facts:
|
||||
elb_target_info:
|
||||
get_unused_target_groups: false
|
||||
instance_id: "{{ ec2.instance_ids[0] }}"
|
||||
<<: *aws_connection_info
|
||||
@@ -340,7 +340,7 @@
|
||||
# wait until all groups associated with this instance are 'healthy' or
|
||||
# 'unused'
|
||||
- name: wait for registration
|
||||
elb_target_facts:
|
||||
elb_target_info:
|
||||
get_unused_target_groups: false
|
||||
instance_id: "{{ ec2.instance_ids[0] }}"
|
||||
<<: *aws_connection_info
|
||||
@@ -373,7 +373,7 @@
|
||||
always:
|
||||
|
||||
- name:
|
||||
debug: msg="********** Tearing down elb_target_facts test dependencies **********"
|
||||
debug: msg="********** Tearing down elb_target_info test dependencies **********"
|
||||
|
||||
- name: remove ec2 instance
|
||||
ec2:
|
||||
@@ -48,7 +48,7 @@
|
||||
- "result.final_snapshot.db_instance_identifier == '{{ instance_id }}'"
|
||||
|
||||
- name: Check that snapshot exists
|
||||
rds_snapshot_facts:
|
||||
rds_snapshot_info:
|
||||
db_snapshot_identifier: "{{ instance_id }}"
|
||||
<<: *aws_connection_info
|
||||
register: result
|
||||
|
||||
@@ -161,7 +161,7 @@
|
||||
- caa is not failed
|
||||
- caa is not changed
|
||||
always:
|
||||
- route53_facts:
|
||||
- route53_info:
|
||||
query: record_sets
|
||||
hosted_zone_id: '{{ z1.zone_id }}'
|
||||
register: z1_records
|
||||
|
||||
Reference in New Issue
Block a user