Hello Harsh,

Please try this one

- name: test
  hosts: test
  tasks:
  - name: warning
    script: C:\\GeneratePassword.ps1






On Wed, 9 Sep 2020 at 11:40, harsh chawda <[email protected]> wrote:

> Hello All,
>
> I am trying to execute a PowerShell script present on remote system. It is
> executing successfully from ansible playbook side.
>
> After execution it should generate a *password.csv* file on the remote
> system, but that file is not getting generated.
>
> *My plabook:*
>
> - name: test
>   hosts: test
>   tasks:
>   - name: warning
>     win_shell: powershell.exe -ExecutionPolicy ByPass -File
> C:\\GeneratePassword.ps1
>
>
> Please help me on this if anyone having any idea.
>
> Thanks in advance
>
> *Regards*
> *Harsh*
>
> --
> 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 [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/ansible-project/6a1bfc60-b5c9-4d28-b97f-3ee1d8bf0ec2o%40googlegroups.com
> <https://groups.google.com/d/msgid/ansible-project/6a1bfc60-b5c9-4d28-b97f-3ee1d8bf0ec2o%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/CABAvFDMACV5rGdrZOygh3OT2iyJZMztVxQcxDhYdS3TPj6PLGg%40mail.gmail.com.

Reply via email to