community.network.icx_copy – Transfer files from or to remote Ruckus ICX 7000 series switches

Note

This plugin is part of the community.network collection (version 3.0.0).

You might already have this collection installed if you are using the ansible package. It is not included in ansible-core. To check whether it is installed, run ansible-galaxy collection list.

To install it, use: ansible-galaxy collection install community.network.

To use it in a playbook, specify: community.network.icx_copy.

Synopsis

  • This module transfers files from or to remote devices running ICX.

Parameters

Parameter Choices/Defaults Comments
download
string
    Choices:
  • running-config
  • startup-config
  • flash_primary
  • flash_secondary
  • bootrom
  • fips-primary-sig
  • fips-secondary-sig
  • fips-bootrom-sig
Name of the resource to be downloaded. Mutually exclusive with upload.
protocol
string / required
    Choices:
  • scp
  • https
Data transfer protocol to be used
public_key
string
    Choices:
  • rsa
  • dsa
public key type to be used to login to scp server
remote_filename
string / required
The name or path of the remote file/resource to be uploaded or downloaded.
remote_pass
string
remote password to be used for scp login.
remote_port
string
The port number of the remote host. Default values will be selected based on protocol type. Default scp:22, http:443
remote_server
string / required
IP address of the remote server
remote_user
string
remote username to be used for scp login.
upload
string
    Choices:
  • running-config
  • startup-config
  • flash_primary
  • flash_secondary
Name of the resource to be uploaded. Mutually exclusive with download.

Notes

Note

Examples

- name: Upload running-config to the remote scp server
  community.network.icx_copy:
    upload: running-config
    protocol: scp
    remote_server: 172.16.10.49
    remote_filename: running.conf
    remote_user: user1
    remote_pass: pass123

- name: Download running-config from the remote scp server
  community.network.icx_copy:
    download: running-config
    protocol: scp
    remote_server: 172.16.10.49
    remote_filename: running.conf
    remote_user: user1
    remote_pass: pass123

- name: Download running-config from the remote scp server using rsa public key
  community.network.icx_copy:
    download: running-config
    protocol: scp
    remote_server: 172.16.10.49
    remote_filename: running.conf
    remote_user: user1
    remote_pass: pass123
    public_key: rsa

- name: Upload startup-config to the remote https server
  community.network.icx_copy:
    upload: startup-config
    protocol: https
    remote_server: 172.16.10.49
    remote_filename: config/running.conf
    remote_user: user1
    remote_pass: pass123

- name: Upload startup-config to the remote https server
  community.network.icx_copy:
    upload: startup-config
    protocol: https
    remote_server: 172.16.10.49
    remote_filename: config/running.conf
    remote_user: user1
    remote_pass: pass123

- name: Download OS image into the flash from remote scp ipv6 server
  community.network.icx_copy:
    download: startup-config
    protocol: scp
    remote_server: ipv6 FE80:CD00:0000:0CDE:1257:0000:211E:729C
    remote_filename: img.bin
    remote_user: user1
    remote_pass: pass123

- name: Download OS image into the secondary flash from remote scp ipv6 server
  community.network.icx_copy:
    Download: flash_secondary
    protocol: scp
    remote_server: ipv6 FE80:CD00:0000:0CDE:1257:0000:211E:729C
    remote_filename: img.bin
    remote_user: user1
    remote_pass: pass123

- name: Download OS image into the secondary flash from remote scp ipv6 server on port 5000
  community.network.icx_copy:
    Download: flash_secondary
    protocol: scp
    remote_server: ipv6 FE80:CD00:0000:0CDE:1257:0000:211E:729C
    remote_port: 5000
    remote_filename: img.bin
    remote_user: user1
    remote_pass: pass123

- name: Download OS image into the primary flash from remote https ipv6 server
  community.network.icx_copy:
    Download: flash_primary
    protocol: https
    remote_server: ipv6 FE80:CD00:0000:0CDE:1257:0000:211E:729C
    remote_filename: images/img.bin
    remote_user: user1
    remote_pass: pass123

- name: Download OS image into the primary flash from remote https ipv6 server on port 8080
  community.network.icx_copy:
    Download: flash_primary
    protocol: https
    remote_server: ipv6 FE80:CD00:0000:0CDE:1257:0000:211E:729C
    remote_port: 8080
    remote_filename: images/img.bin
    remote_user: user1
    remote_pass: pass123

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key Returned Description
changed
boolean
always
true when downloaded any configuration or flash. false otherwise.



Authors

  • Ruckus Wireless (@Commscope)

© 2012–2018 Michael DeHaan
© 2018–2021 Red Hat, Inc.
Licensed under the GNU General Public License version 3.
https://docs.ansible.com/ansible/latest/collections/community/network/icx_copy_module.html