Skip to content
This repository was archived by the owner on May 27, 2024. It is now read-only.
This repository was archived by the owner on May 27, 2024. It is now read-only.

copy files from linux server to file shared on windows server #318

@aakilo

Description

@aakilo

i have created these playfbook and invetory but it does not work when iexecute ansible-playbook -i inventory playbook.yml
inventory :
[windows]
10.x.x.x
[windows:vars]
ansible_user=xxxx
ansible_password=xxxx
ansible_winrm_transport: basic

playbook.yml

  • hosts: windows

    tasks:

    • name: Copy file from switch to Windows server
      win_copy:
      src: "/path/file.txt"
      dest: 'D:\config'
      delegate_to: localhost # Run this task on the Ansible server

what i should add ?????

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions