arubanetworks / arubanetworks.aos_switch / 1.7.0 / module / arubaoss_file_transfer implements rest api's for file transfer from/to device | "added in version" 2.6.0 of arubanetworks.aos_switch" Authors: Ashish Pant (@hpe) preview | supported by communityarubanetworks.aos_switch.arubaoss_file_transfer (1.7.0) — module
Install with ansible-galaxy collection install arubanetworks.aos_switch:==1.7.0
collections: - name: arubanetworks.aos_switch version: 1.7.0
This implements rest api's for file transfer from/to device. The file get copied to from a http/https server. Server needs to be pre-configured to make use of this module. This module will not do firmware-ugrade but can copy image to flash. User can then use arubaoss_reboot to bringup device with that flash, thus provides firmware-upgrade
- name: image download arubaoss_file_transfer: file_url: "http://192.168.1.2/WC_16_07_REL_XANADU_QA_062618.swi" file_type: "FTT_FIRMWARE" action: "FTA_DOWNLOAD"
host: description: 'Specifies the DNS host name or address for connecting to the remote device over the specified transport. The value of host is used as the destination address for the transport. ' type: str port: description: 'Specifies the port to use when building the connection to the remote device. ' type: int action: choices: - FTA_DOWNLOAD - FTA_UPLOAD default: FTA_DOWNLOAD description: - Type of action upload/download. required: false timeout: description: 'Specifies the timeout in seconds for communicating with the network device for either connecting or sending commands. If the timeout is exceeded before the operation is completed, the module will error. ' type: int use_ssl: description: 'Configures use SSL (HTTPS) for access to the remote device. ' type: bool file_url: description: - Location of the file to which file needs to be transfered or from file needs to downloded to switch. This is http/https server, which needs to configured with default ports. required: true password: description: 'Specifies the password to use to authenticate the connection to the remote device. This value is used to authenticate the SSH session. If the value is not specified in the task, the value of environment variable ANSIBLE_NET_PASSWORD will be used instead. ' type: str provider: description: A dict object containing connection details. suboptions: api_version: default: None description: 'Configures (force) API version (vX.Y) for acces to the remote device. ' type: str host: description: 'Specifies the DNS host name or address for connecting to the remote device over the specified transport. The value of host is used as the destination address for the transport. ' type: str password: description: 'Specifies the password to use to authenticate the connection to the remote device. This value is used to authenticate the SSH session. If the value is not specified in the task, the value of environment variable ANSIBLE_NET_PASSWORD will be used instead. ' type: str port: description: 'Specifies the port to use when building the connection to the remote device. ' type: int ssh_keyfile: description: 'Specifies the SSH key to use to authenticate the connection to the remote device. This value is the path to the key used to authenticate the SSH session. If the value is not specified in the task, the value of environment variable ANSIBLE_NET_SSH_KEYFILE will be used instead. ' type: path timeout: description: 'Specifies the timeout in seconds for communicating with the network device for either connecting or sending commands. If the timeout is exceeded before the operation is completed, the module will error. ' type: int transport: default: aossapi description: 'Configures the transport (aossapi or network_cli) mode. ' type: str use_proxy: default: false description: 'Configures use (Local) Proxy for access to the remote device. ' type: bool use_ssl: description: 'Configures use SSL (HTTPS) for access to the remote device. ' type: bool username: description: 'Configures the username to use to authenticate the connection to the remote device. This value is used to authenticate the SSH session. If the value is not specified in the task, the value of environment variable ANSIBLE_NET_USERNAME will be used instead. ' type: str validate_certs: default: false description: 'Configures validation of certification for access to the remote device. ' type: bool type: dict username: description: 'Configures the username to use to authenticate the connection to the remote device. This value is used to authenticate the SSH session. If the value is not specified in the task, the value of environment variable ANSIBLE_NET_USERNAME will be used instead. ' type: str copy_iter: default: 20 description: - Approx max iteration to wait for image copy to get completed. file_type: choices: - FTT_CONFIG - FTT_FIRMWARE - FTT_EVENT_LOGS - FTT_CRASH_FILES - FTT_SYSTEM_INFO - FTT_SHOW_TECH - FTT_DEBUG_LOGS default: FTT_FIRMWARE description: - Type of file that needs to be transfered. required: false boot_image: choices: - BI_PRIMARY_IMAGE - BI_SECONDARY_IMAGE default: BI_PRIMARY_IMAGE description: - Flash where image needs to be copied api_version: default: None description: 'Configures (force) API version (vX.Y) for acces to the remote device. ' type: str ssh_keyfile: description: 'Specifies the SSH key to use to authenticate the connection to the remote device. This value is the path to the key used to authenticate the SSH session. If the value is not specified in the task, the value of environment variable ANSIBLE_NET_SSH_KEYFILE will be used instead. ' type: path validate_certs: default: false description: 'Configures validation of certification for access to the remote device. ' type: bool show_tech_option: choices: - STO_BASIC - STO_ALL - STO_BUFFERS - STO_INSTRUMENTATION - STO_MSTP - STO_OOBM - STO_RAPID_PVST - STO_ROUTE - STO_SMART_LINK - STO_STATISTICS - STO_TRANSCEIVERS - STO_TUNNEL_INTERCEPT - STO_TUNNEL_TAP - STO_TUNNEL_VXLAN - STO_COMPONENTS description: - Specifies type of show tech command to be executed. required: false