How to use an URL in Ansible Playbook

0 votes

Hi Guys,

I have created one ansible-playbook. I want to use one URL in this playbook. How can I do that? 

Aug 20, 2020 in Ansible by akhtar
• 38,230 points
1,728 views

1 answer to this question.

0 votes

Hi@akhtar,

You can use the get_url module in Ansible. This module is used to download files using URL as shown below.

 - name: Copy web page from URL
    get_url:
      dest: "/var/www/nadim"
      url: "https://raw.githubusercontent.com/nadim70/webserver/master/index.html"
    when: y.failed == false
    tags: web1

answered Aug 20, 2020 by MD
• 95,440 points

Related Questions In Ansible

0 votes
1 answer
0 votes
1 answer

How to create an Elastic Load Balancer in AWS with Ansible Playbook?

Hi@akhtar, You can find one module in ansible ...READ MORE

answered Oct 12, 2020 in Ansible by MD
• 95,440 points
903 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,440 points
557 views
0 votes
1 answer

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

Hi@akhtar, Ansible has one module to copy AMI ...READ MORE

answered Dec 4, 2020 in Ansible by MD
• 95,440 points
757 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 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
3,458 views
+2 votes
1 answer
0 votes
1 answer

How to use conditions in Ansible-Playbook?

Hi@akhtar, Traditional programming language usually uses the if-else ...READ MORE

answered Aug 20, 2020 in Ansible by MD
• 95,440 points
1,248 views
0 votes
1 answer

How to use loop in Ansible playbook?

Hi@akhtar, Sometimes you want to repeat a task ...READ MORE

answered Sep 1, 2020 in Ansible by MD
• 95,440 points
918 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