# Playbook para download via web com problema

**URL:** <https://forum.ansible.com/t/playbook-para-download-via-web-com-problema/11214>\
**Category:** Get Help\
**Created:** [November 29, 2024, 1:46am UTC](https://forum.ansible.com/t/playbook-para-download-via-web-com-problema/11214 "2024-11-29T01:46:01Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![jeferson\_nascimento](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/jeferson_nascimento/32/5589_2.png) [@jeferson\_nascimento](https://forum.ansible.com/u/jeferson_nascimento)\
**Post date:** [November 29, 2024, 1:46am UTC](https://forum.ansible.com/t/playbook-para-download-via-web-com-problema/11214/1 "2024-11-29T01:46:01Z")

</div>

Good evening everyone, I hope you find it well.  
I have a problem creating a playbook to automate. This means downloading via the web through the proxy and installing. Even though I directly copy the Ansible website example, I am unable to validate it. Has anyone gone through the same situation and can give me an idea, I would appreciate it.

---

<div class="post-metadata">

**Author:** ![chris](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/chris/32/293_2.png) [@chris](https://forum.ansible.com/u/chris)\
**Post date:** [November 29, 2024, 9:46am UTC](https://forum.ansible.com/t/playbook-para-download-via-web-com-problema/11214/2 "2024-11-29T09:46:34Z")

</div>

Can you post the URL to the example that you are copying and what you have written?

Could you try running [yamllint](https://github.com/adrienverge/yamllint) and [ansible-lint](https://github.com/ansible/ansible-lint) on the code?

Can you run `ansible-playbook` using `-vvv` to get the verbose output in case that has more details regarding the issue?

Could you post any code here using [fenced code blocks](https://docs.github.com/en/get-started/writing-on-github/working-with-advanced-formatting/creating-and-highlighting-code-blocks) please as it make it easier to read, thanks!

---

<div class="post-metadata">

**Author:** ![jeferson\_nascimento](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/jeferson_nascimento/32/5589_2.png) [@jeferson\_nascimento](https://forum.ansible.com/u/jeferson_nascimento)\
**Post date:** [November 29, 2024, 4:20pm UTC](https://forum.ansible.com/t/playbook-para-download-via-web-com-problema/11214/3 "2024-11-29T16:20:57Z")

</div>

Hello, of course I leave an example below. Because if you comment out the proxy lines in the file, it doesn’t even go through, I imagine it would be like this because I have an active proxy on my network so I have to make it go through it. And another network off when downloading and installing the .deb file. I hope you understand. Thank you in advance for your attention.

 ![2024-11-29_13-02](https://us1.discourse-cdn.com/ansible/original/2X/a/a8a3f3a1435f47220fb39ecf9db52459a88bc10d.png)

---

<div class="post-metadata">

**Author:** ![chris](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/chris/32/293_2.png) [@chris](https://forum.ansible.com/u/chris)\
**Post date:** [November 29, 2024, 4:29pm UTC](https://forum.ansible.com/t/playbook-para-download-via-web-com-problema/11214/4 "2024-11-29T16:29:49Z")

</div>

I don’t think there is a `ansible.builtin.environment` module, where did you get that from, it sounds like an AI hallucination?

Try this:

```yaml
    - name: Install Google Chrome
      ansible.builtin.apt:
        deb: https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
      environment:
        HTTPS_PROXY: http://10.254.0.254:8080

```

See [the documentation](https://docs.ansible.com/ansible/latest/playbook_guide/playbooks_environment.html#setting-the-remote-environment-in-a-task) — this is a more reliable source than AI!

---

<div class="post-metadata">

**Author:** ![jeferson\_nascimento](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/jeferson_nascimento/32/5589_2.png) [@jeferson\_nascimento](https://forum.ansible.com/u/jeferson_nascimento)\
**Post date:** [December 2, 2024, 11:14am UTC](https://forum.ansible.com/t/playbook-para-download-via-web-com-problema/11214/5 "2024-12-02T11:14:26Z")

</div>

Good morning. I made the adjustments this morning and it worked. Yes, I ask for your attention and help.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/ansible/original/1X/1882d9a01da5d8996a862359b0913cc568a39b84.svg) [@system](https://forum.ansible.com/u/system)\
**Post date:** [January 1, 2025, 11:15am UTC](https://forum.ansible.com/t/playbook-para-download-via-web-com-problema/11214/6 "2025-01-01T11:15:08Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
