How to copy an AMI in a different region using Ansible Playbook

0 votes

Hi Team,

I have one AMI in AWS. I want to copy the AMI in a different region. How can I do that using Ansible Playbook?

Dec 4, 2020 in Ansible by akhtar
• 38,260 points
992 views

1 answer to this question.

0 votes

Hi@akhtar,

Ansible has one module to copy AMI in different regions. You can use the below code in your Ansible Playbook.

# Basic AMI Copy
- ec2_ami_copy:
    source_region: us-east-1
    region: eu-west-1
    source_image_id: ami-xxxxxxx
answered Dec 4, 2020 by MD
• 95,460 points

Related Questions In Ansible

0 votes
2 answers

How to create a directory in remote nodes using Ansible-Playbook?

You can read install and setup apache ...READ MORE

answered Aug 23, 2020 in Ansible by anonymous
• 160 points
4,276 views
0 votes
1 answer

How to add multiple lines in a file using Ansible playbook?

Hi@akhtar, You can update your file using lineinfile ...READ MORE

answered Sep 16, 2020 in Ansible by MD
• 95,460 points
26,636 views
0 votes
1 answer

How to mount a dvd in a folder using Ansible playbook?

Hi@akhtar, Ansible has the mount module that is idempotent ...READ MORE

answered Sep 16, 2020 in Ansible by MD
• 95,460 points
2,609 views
0 votes
1 answer

How to create an encrypted bucket in AWS using Ansible Playbook?

Hi@akhtar, Sometimes it is required to encrypt the ...READ MORE

answered Dec 4, 2020 in Ansible by MD
• 95,460 points
800 views
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

How to overwrite the content of a file in remote systems using Ansible playbook?

Hi@akhtar, You can find one argument in the ...READ MORE

answered Aug 2, 2020 in Ansible by MD
• 95,460 points
14,409 views
0 votes
1 answer

How to create a security group in AWS using Ansible-Playbook?

Hi@akhtar, You can use the ec2_group module in ...READ MORE

answered Aug 13, 2020 in Ansible by MD
• 95,460 points
3,825 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP