From e4908b84a7e8a03f874a1215f55d902ccea47c63 Mon Sep 17 00:00:00 2001 From: Jack Ivanov Date: Mon, 26 Aug 2019 15:02:47 +0200 Subject: [PATCH] lightsail_region_facts fix --- library/lightsail_region_facts.py | 2 +- roles/cloud-lightsail/tasks/prompts.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/library/lightsail_region_facts.py b/library/lightsail_region_facts.py index 8da4c00..849acf2 100644 --- a/library/lightsail_region_facts.py +++ b/library/lightsail_region_facts.py @@ -93,7 +93,7 @@ def main(): response = client.get_regions( includeAvailabilityZones=False ) - module.exit_json(changed=False, results=response) + module.exit_json(changed=False, data=response) except (botocore.exceptions.ClientError, Exception) as e: module.fail_json(msg=str(e), exception=traceback.format_exc()) diff --git a/roles/cloud-lightsail/tasks/prompts.yml b/roles/cloud-lightsail/tasks/prompts.yml index be3c3e1..b1584f4 100644 --- a/roles/cloud-lightsail/tasks/prompts.yml +++ b/roles/cloud-lightsail/tasks/prompts.yml @@ -32,7 +32,7 @@ - name: Set facts about the regions set_fact: - lightsail_regions: "{{ _lightsail_regions.results.regions | sort(attribute='name') }}" + lightsail_regions: "{{ _lightsail_regions.data.regions | sort(attribute='name') }}" - name: Set the default region set_fact: