use Ansible to install a .exe program on windows machine

Hi All,

I am new to Ansible and I want to use Ansible to install a .exe program on windows machines.

I have a Ansible server on a CentOs linux machine and 10 windows 2012 R2 machines where I want to install a .exe program on each windows machine.

If I want to use win_chocolatey, Can you tell me if I have to install chocolatey package on every windows machine ?

Can you tell me if I must do something on Linux Centos Ansible server to run playbook with win_chocolatey ?

Thanks in advance,

Viet Minh

If I want to use win_chocolatey, Can you tell me if I have to install chocolatey package on every windows machine ?

win_chocolatey will ensure Chocolatey is installed if it isn’t present. This requires an active internet connection by default but in the upcoming 2.7 release you can set an offline source to install it. Same thing with the packages it automatically sources from the public repo on the internet but you can specify an offline internal source accessible within your organisation if that is what you want to do.

Can you tell me if I must do something on Linux Centos Ansible server to run playbook with win_chocolatey ?

Ensure that Ansible can connect to your Windows host and that’s it. The win_chocolatey module is run on the Windows host only, Ansible does all the abstraction to execute it and return the results back.

While I do highly recommend you use win_chocolatey for all this as it makes things so much simpler you are not limited to using it. You can use win_package or even just win_command to install an executable manually, the trouble with this approach is you need to know what the silent install arguments are when invoking the executable. Chocolatey does all this for you and makes it quite simple to uninstall and upgrade packages in the future.

Thanks

Jordan

hi,

can you briefly explain how you configure of ansible+ windows .

i did windows host machine installed virtual box and at windows client side i configured winrm, powershell3.0 .

i am facing the ssl certificate error .

help me to any easy waY to solve this process.

regards
shivaji

Hi Jordan,

Thanks a lot for your help

Regards

Viet Minh