Hmm, not sure what is going on there.

Try running with -v so you can see stdout from script module output

Also check the event log to see if there is anything there.

When run on the server do  you have accept UAC prompt?  Might need to turn 
that off to run remotely via ansible.

Hope this helps,

Jon

On Thursday, 11 February 2016 17:11:31 UTC, Mark Matthews wrote:
>
> Hi
>
> I have a playbook that is running the below powershell script.
> If I run the script on the actual server it works perfectly. But when I 
> run the playbook nothing happens on the server.
> The job returns as changed....but nothing has happened.
>
> The playbook does seem to run quite quickly and I was wondering if Ansible 
> is stopping the Powershell job before it completes? Can Ansible do that, or 
> does it not have any effect on the script after it has been executed? If it 
> does have an efffect on stopping the job are you able to put a wait on the 
> job to allow the powershell script to complete?
>
> $InstallPath = "C:\Program Files\Octopus Deploy\Tentacle"
> $Server = $InstallPath + "\Tentacle.exe"
>
> # Start-Process "C:\Temp\Octopus.Tentacle.3.0.10.2278-x64.msi" /qn -Wait
>
> Start-Process $Server 'create-instance --instance "Tentacle" --config 
> "C:\Octopus\Tentacle.config"' -Wait
> Start-Process $Server 'new-certificate --instance "Tentacle" --if-blank' 
> -Wait
> Start-Process $Server 'configure --instance "Tentacle" --reset-trust' -Wait
> Start-Process $Server 'configure --instance "Tentacle" --home "C:\Octopus" 
> --app "C:\Octopus\Applications" --port "10933" --noListen "False"' -Wait
> Start-Process $Server 'configure --instance "Tentacle" --trust 
> "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"' -Wait
> Start-Process $Server 'service --instance "Tentacle" --install --start' 
> -Wait
>
>
> Cheers
> Mark
>

-- 
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/f4159a51-c5c6-444c-9a2f-9eba25d2d37e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to