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

=====================================

It runs but doesn't install , logs below , please help 



[root@dev-mmadmin-lx01 playbooks]# ansible-playbook win_firefox_install.yml 
-vvvv
Using /etc/ansible/ansible.cfg as config file
Loaded callback default of type stdout, v2.0

PLAYBOOK: win_firefox_install.yml 
**********************************************
1 plays in win_firefox_install.yml

PLAY [install] 
*****************************************************************

TASK [setup] 
*******************************************************************
<dev-ansiblewn01.ads.xyz.com> ESTABLISH WINRM CONNECTION FOR USER: othello 
on PORT 5986 TO dev-ansiblewn01.ads.xyz.com
<dev-ansiblewn01.ads.xyz.com> EXEC Set-StrictMode -Version Latest
(New-Item -Type Directory -Path $env:temp -Name 
"ansible-tmp-1470810586.81-251734432475517").FullName | Write-Host 
-Separator '';
<dev-ansiblewn01.ads.xyz.com> PUT "/tmp/tmpmm0Fwb" TO 
"C:\Users\Administrator\AppData\Local\Temp\ansible-tmp-1470810586.81-251734432475517\setup.ps1"
<dev-ansiblewn01.ads.xyz.com> EXEC Set-StrictMode -Version Latest
Try
{
& 
'C:\Users\Administrator\AppData\Local\Temp\ansible-tmp-1470810586.81-251734432475517\setup.ps1'
}
Catch
{
$_obj = @{ failed = $true }
If ($_.Exception.GetType)
{
$_obj.Add('msg', $_.Exception.Message)
}
Else
{
$_obj.Add('msg', $_.ToString())
}
If ($_.InvocationInfo.PositionMessage)
{
$_obj.Add('exception', $_.InvocationInfo.PositionMessage)
}
ElseIf ($_.ScriptStackTrace)
{
$_obj.Add('exception', $_.ScriptStackTrace)
}
Try
{
$_obj.Add('error_record', ($_ | ConvertTo-Json | ConvertFrom-Json))
}
Catch
{
}
Echo $_obj | ConvertTo-Json -Compress -Depth 99
Exit 1
}
Finally { Remove-Item 
"C:\Users\Administrator\AppData\Local\Temp\ansible-tmp-1470810586.81-251734432475517"
 
-Force -Recurse -ErrorAction SilentlyContinue }
ok: [dev-ansiblewn01.ads.xyz.com] => {"ansible_facts": 
{"ansible_architecture": "64-bit", "ansible_date_time": {"date": 
"8/10/2016", "day": "10", "hour": "02", "iso8601": "2016-08-10T02:30:21", 
"minute": "30", "month": "08", "year": "2016"}, "ansible_distribution": 
"Microsoft Windows NT 6.3.9600.0", "ansible_distribution_version": 
"6.3.9600.0", "ansible_env": {"ALLUSERSPROFILE": "C:\\ProgramData", 
"APPDATA": "C:\\Users\\Administrator\\AppData\\Roaming", "COMPUTERNAME": 
"DEV-ANSIBLEWN01", "ComSpec": "C:\\Windows\\system32\\cmd.exe", 
"CommonProgramFiles": "C:\\Program Files\\Common Files", 
"CommonProgramFiles(x86)": "C:\\Program Files (x86)\\Common Files", 
"CommonProgramW6432": "C:\\Program Files\\Common Files", 
"FP_NO_HOST_CHECK": "NO", "LOCALAPPDATA": 
"C:\\Users\\Administrator\\AppData\\Local", "MODULE_COMPLEX_ARGS": 
"{\"_ansible_version\": \"2.1.0.0\", \"_ansible_selinux_special_fs\": 
[\"fuse\", \"nfs\", \"vboxsf\", \"ramfs\"], \"_ansible_no_log\": false, 
\"_ansible_verbosity\": 4, \"_ansible_syslog_facility\": \"LOG_USER\", 
\"gather_subset\": \"all\", \"_ansible_diff\": false, \"_ansible_debug\": 
false, \"_ansible_check_mode\": false}", "NUMBER_OF_PROCESSORS": "2", "OS": 
"Windows_NT", "PATHEXT": 
".COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC;.CPL", 
"PROCESSOR_ARCHITECTURE": "AMD64", "PROCESSOR_IDENTIFIER": "Intel64 Family 
6 Model 63 Stepping 2, GenuineIntel", "PROCESSOR_LEVEL": "6", 
"PROCESSOR_REVISION": "3f02", "PROMPT": "$P$G", 
"PSExecutionPolicyPreference": "Unrestricted", "PSModulePath": 
"C:\\Users\\Administrator\\Documents\\WindowsPowerShell\\Modules;C:\\Program 
Files\\WindowsPowerShell\\Modules;C:\\Windows\\system32\\WindowsPowerShell\\v1.0\\Modules",
 
"PUBLIC": "C:\\Users\\Public", "Path": 
"C:\\Windows\\system32;C:\\Windows;C:\\Windows\\System32\\Wbem;C:\\Windows\\System32\\WindowsPowerShell\\v1.0",
 
"ProgramData": "C:\\ProgramData", "ProgramFiles": "C:\\Program Files", 
"ProgramFiles(x86)": "C:\\Program Files (x86)", "ProgramW6432": 
"C:\\Program Files", "SystemDrive": "C:", "SystemRoot": "C:\\Windows", 
"TEMP": "C:\\Users\\ADMINI~1\\AppData\\Local\\Temp", "TMP": 
"C:\\Users\\ADMINI~1\\AppData\\Local\\Temp", "USERDOMAIN": 
"DEV-ANSIBLEWN01", "USERNAME": "othello", "USERPROFILE": 
"C:\\Users\\Administrator", "windir": "C:\\Windows"}, "ansible_fqdn": 
"dev-ansiblewn01.ads.xyz.com", "ansible_hostname": "DEV-ANSIBLEWN01", 
"ansible_interfaces": [{"default_gateway": "10.191.49.129", "dns_domain": 
"ads.xyz.com", "interface_index": 12, "interface_name": "vmxnet3 Ethernet 
Adapter"}], "ansible_ip_addresses": ["10.191.49.226"], "ansible_lastboot": 
"2016-07-19 02:29:46Z", "ansible_os_family": "Windows", "ansible_os_name": 
"Microsoft Windows Server 2012 R2 Standard", "ansible_powershell_version": 
4, "ansible_system": "Win32NT", "ansible_totalmem": 3220688896, 
"ansible_uptime_seconds": 1900835, "ansible_winrm_certificate_expires": 
"2017-07-19 05:58:38"}, "changed": false, "invocation": {"module_name": 
"setup"}}

TASK [InstallFF] 
***************************************************************
task path: /etc/ansible/playbooks/win_firefox_install.yml:5
<dev-ansiblewn01.ads.xyz.com> ESTABLISH WINRM CONNECTION FOR USER: othello 
on PORT 5986 TO dev-ansiblewn01.ads.xyz.com
<dev-ansiblewn01.ads.xyz.com> EXEC Set-StrictMode -Version Latest
(New-Item -Type Directory -Path $env:temp -Name 
"ansible-tmp-1470810630.28-133554528762796").FullName | Write-Host 
-Separator '';
<dev-ansiblewn01.ads.xyz.com> PUT "/tmp/tmp2CW_lI" TO 
"C:\Users\Administrator\AppData\Local\Temp\ansible-tmp-1470810630.28-133554528762796\win_msi.ps1"
<dev-ansiblewn01.ads.xyz.com> EXEC Set-StrictMode -Version Latest
Try
{
& 
'C:\Users\Administrator\AppData\Local\Temp\ansible-tmp-1470810630.28-133554528762796\win_msi.ps1'
}
Catch
{
$_obj = @{ failed = $true }
If ($_.Exception.GetType)
{
$_obj.Add('msg', $_.Exception.Message)
}
Else
{
$_obj.Add('msg', $_.ToString())
}
If ($_.InvocationInfo.PositionMessage)
{
$_obj.Add('exception', $_.InvocationInfo.PositionMessage)
}
ElseIf ($_.ScriptStackTrace)
{
$_obj.Add('exception', $_.ScriptStackTrace)
}
Try
{
$_obj.Add('error_record', ($_ | ConvertTo-Json | ConvertFrom-Json))
}
Catch
{
}
Echo $_obj | ConvertTo-Json -Compress -Depth 99
Exit 1
}
Finally { Remove-Item 
"C:\Users\Administrator\AppData\Local\Temp\ansible-tmp-1470810630.28-133554528762796"
 
-Force -Recurse -ErrorAction SilentlyContinue }
changed: [dev-ansiblewn01.ads.xyz.com] => {"changed": true, "invocation": 
{"module_name": "win_msi"}, "log": ""}

PLAY RECAP 
*********************************************************************
dev-ansiblewn01.ads.xyz.com : ok=2    changed=1    unreachable=0    failed=0




-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ansible-project+unsubscr...@googlegroups.com.
To post to this group, send email to ansible-project@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/2f4cad1a-19c2-425b-9e19-2dd1bf5553d6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to