- Docs »
- vsphere_copy - Copy a file to a vCenter datastore
-
You are reading an unmaintained version of the Ansible documentation. Unmaintained Ansible versions can contain unfixed security vulnerabilities (CVE). Please upgrade to a maintained version. See the latest Ansible documentation.
vsphere_copy - Copy a file to a vCenter datastore
- Upload files to a vCenter datastore
Parameter |
Choices/Defaults |
Comments |
datacenter
required |
|
The datacenter on the vCenter server that holds the datastore.
|
datastore
required |
|
The datastore on the vCenter server to push files to.
|
host
required |
|
The vCenter server on which the datastore is available.
aliases: hostname
|
login
required |
|
The login name to authenticate on the vCenter server.
aliases: username
|
password
required |
|
The password to authenticate on the vCenter server.
|
path
required |
|
The file to push to the datastore on the vCenter server.
|
src
required |
|
The file to push to vCenter
|
validate_certs
bool |
|
If no , SSL certificates will not be validated. This should only be set to no when no other option exists.
|
Note
- This module ought to be run from a system that can access vCenter directly and has the file to transfer. It can be the normal remote target or you can change it either by using
transport: local
or using delegate_to
.
- Tested on vSphere 5.5
- vsphere_copy:
host: vhost
login: vuser
password: vpass
src: /some/local/file
datacenter: DC1 Someplace
datastore: datastore1
path: some/remote/file
transport: local
- vsphere_copy:
host: vhost
login: vuser
password: vpass
src: /other/local/file
datacenter: DC2 Someplace
datastore: datastore2
path: other/remote/file
delegate_to: other_system
This module is flagged as preview which means that it is not guaranteed to have a backwards compatible interface.
This module is flagged as community which means that it is maintained by the Ansible Community. See Module Maintenance & Support for more info.
For a list of other modules that are also maintained by the Ansible Community, see here.
Hint
If you notice any issues in this documentation you can edit this document to improve it.