# How to install exe file on windows using ansible , e.g. firefox.exe

**URL:** <https://forum.ansible.com/t/how-to-install-exe-file-on-windows-using-ansible-e-g-firefox-exe/22258>\
**Category:** Ansible Project\
**Tags:** windows\
**Created:** [August 10, 2016, 6:35am UTC](https://forum.ansible.com/t/how-to-install-exe-file-on-windows-using-ansible-e-g-firefox-exe/22258 "2016-08-10T06:35:54Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Chandra\_Pandey](https://avatars.discourse-cdn.com/v4/letter/c/87869e/32.png) [@Chandra\_Pandey](https://forum.ansible.com/u/Chandra_Pandey)\
**Post date:** [August 10, 2016, 6:35am UTC](https://forum.ansible.com/t/how-to-install-exe-file-on-windows-using-ansible-e-g-firefox-exe/22258/1 "2016-08-10T06:35:54Z")

</div>

ansible play book

root@dev-mmadmin-lx01 playbooks]# cat win\_firefox\_install.yml

- name: install  
hosts: wintestserverchandra

tasks:

- name: InstallFF  
win\_msi: path=d:\install\Firefox.exe

---

<div class="post-metadata">

**Author:** ![Mike\_Fennemore](https://avatars.discourse-cdn.com/v4/letter/m/45deac/32.png) [@Mike\_Fennemore](https://forum.ansible.com/u/Mike_Fennemore)\
**Post date:** [August 10, 2016, 1:34pm UTC](https://forum.ansible.com/t/how-to-install-exe-file-on-windows-using-ansible-e-g-firefox-exe/22258/2 "2016-08-10T13:34:00Z")

</div>

I would try win\_package as the alternative module for installing the exe.

---

<div class="post-metadata">

**Author:** ![Trond\_Hindenes](https://avatars.discourse-cdn.com/v4/letter/t/96bed5/32.png) [@Trond\_Hindenes](https://forum.ansible.com/u/Trond_Hindenes)\
**Post date:** [August 10, 2016, 7:42pm UTC](https://forum.ansible.com/t/how-to-install-exe-file-on-windows-using-ansible-e-g-firefox-exe/22258/3 "2016-08-10T19:42:26Z")

</div>

The chocolatey module (win\_chocolatey) can also install firefox.

---

<div class="post-metadata">

**Author:** ![Hitesh](https://avatars.discourse-cdn.com/v4/letter/h/8e7dd6/32.png) [@Hitesh](https://forum.ansible.com/u/Hitesh)\
**Post date:** [April 26, 2017, 10:45pm UTC](https://forum.ansible.com/t/how-to-install-exe-file-on-windows-using-ansible-e-g-firefox-exe/22258/4 "2017-04-26T22:45:01Z")

</div>

Hello Mike,

I am having trouble installing a software(thru ansible) using the executable provided by the vendor. I approached the vendor and asked if they could provide us with a msi to make things easier but unfortunately  
Anyway, I generated a response file setup.iss using -r switch. When I run _ **Setup.exe -s setup.iss** _ in powershell locally on the vm, it installs the software in ~10seconds.  
I include the path to the executable and same command in a powershell script and run it from ansible, it doesn’t install it. Although the task doesn’t error out. It says changed. I believe it starts installing and then exits the task abruptly. Did you / anyone out there encounter a problem like this? Please let me know if you have a solution for this.  
My target machine is a 2008 R2, updated .Net Framework and WMF and thus powershell… My ansible version is 2.3.0.0

Thanks,  
Hitesh

---

<div class="post-metadata">

**Author:** ![j.r.hawkesworth](https://avatars.discourse-cdn.com/v4/letter/j/a3d4f5/32.png) [@j.r.hawkesworth](https://forum.ansible.com/u/j.r.hawkesworth)\
**Post date:** [May 2, 2017, 9:12pm UTC](https://forum.ansible.com/t/how-to-install-exe-file-on-windows-using-ansible-e-g-firefox-exe/22258/5 "2017-05-02T21:12:45Z")

</div>

I suggest you try to find any command line options that log the installation to a file. That way maybe you can find out what point the installer has stopped working.

Some installers expect to have the windows graphical user interface available, so it is worth checking to see if there is a /quiet or /qn option for the installer.

Does the installer need access to remote files? If so, sometimes this will stop the installer from working via ansible but you can usually work around this if you have to domain login and configure ansible to enable Kerberos authorization delegation.

Hope this helps.

Jon
