Need help with win_package [msi file with TRANSFORMS]

Hello,

I have some trouble with win_package module, i’m trying to install a msi package with a deployment file, so i’ve wrote this task:

- name:
win_package:
path: C:\tmp\The msi package.msi
arguments:
- /passive
- TRANSFORMS=‘“Group Policy Deployment.mst”’
state: present

The problem is that the Windows installer process always stay inactive

Someone’s know the exact synthax for this task?

Best Regards
Julien.

Try putting all the arguments on one line perhaps? I don’t think ‘arguments’ takes a list, just a string:

- name:
win_package:
path: C:\tmp\The msi package.msi
arguments: /passive TRANSFORMS=‘“Group Policy Deployment.mst”’
state: present

MSIs seem to have different command line switches based on which installer technology they were created with. If you can’t find out from wherever you got the .msi from what the correct command line switches for an unattended installation.

You might need a full path (or relative path from the HOMEPATH of the user that ansible is running as) to the .mst file as well.

Hope this helps

Jon

Hi Jon and thank’s for the reply,

I’ve tried to put all arguments in one line, but i have the same result, my playbook stay stuck :

The thing that i don’t understand is the command with the same command (msiexec /i The msi package.msi /passive TRANSFORMS=‘“Group Policy Deployment.mst”’) on powershell works fine

Have you got any other solutions?
Sorry for the late of the answer, i were on vacation

Best Regards,
Julien.

Missed the " " on the command, here it is :

msiexec /i “C:\tmp\The msi package.msi” /passive TRANSFORMS=‘“Group Policy Deployment.mst”’

There’s lots of ways msi installations can fail.

You can debug it a bit by passing the logging output switches in the arguments and then reviewing the logging from msi.

I would probably take a pragmatic approach and use win_shell to run msiexec, perhaps with the creates option to stop it from reattempting the installing if already installed.

Jon