How to remove an S3 bucket using Ansible playbook

0 votes

Hi Team,

 I have created one S3 bucket in AWS. I want to delete the bucket using the Ansible Playbook. How can I do that?

Dec 4, 2020 in Ansible by akhtar
• 38,180 points
121 views

1 answer to this question.

0 votes

Hi@akhtar,

You can create or remove an S3 bucket from AWS. The below s3_bucket module is used to remove a bucket from AWS as well.

# Remove an s3 bucket and any keys it contains
- amazon.aws.s3_bucket:
    name: mys3bucket
    state: absent
    force: yes
answered Dec 4, 2020 by MD
• 95,220 points

Related Questions In Ansible

0 votes
1 answer
0 votes
1 answer

How to remove yum repository using Ansible playbook?

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

answered Aug 4, 2020 in Ansible by MD
• 95,220 points
749 views
0 votes
1 answer

How to launch an EC2 instance using Ansible Playbook?

Hi@akhtar, Ansible has one module named ec2. This ...READ MORE

answered Aug 12, 2020 in Ansible by MD
• 95,220 points
450 views
+2 votes
1 answer

Deploy Docker Containers from Docker Cloud

To solve this problem, I followed advice ...READ MORE

answered Sep 3, 2018 in AWS by Priyaj
• 58,120 points
1,197 views
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 26, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
1,139 views
0 votes
1 answer

How to create an S3 bucket using Ansible Playbook?

Hi@akhtar, Ansible has a module that can create ...READ MORE

answered Dec 4, 2020 in Ansible by MD
• 95,220 points
372 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,220 points
79 views