From d0a8b136ea4af698ee27f4495f113abbee43cdea Mon Sep 17 00:00:00 2001 From: Shiva Shankar Vaddepally Date: Thu, 12 Dec 2024 09:48:29 +0000 Subject: [PATCH] mend issues --- plugins/connection/ssh_netscaler_adc.py | 52 ++++--------------------- 1 file changed, 8 insertions(+), 44 deletions(-) diff --git a/plugins/connection/ssh_netscaler_adc.py b/plugins/connection/ssh_netscaler_adc.py index 4820902b7..a3d61190d 100644 --- a/plugins/connection/ssh_netscaler_adc.py +++ b/plugins/connection/ssh_netscaler_adc.py @@ -29,12 +29,9 @@ - The only authentication method that works with this plugin is with ssh key file. - The input options supported by this connection plugin are the same as the ssh connection plugin of Ansible. author: - - name: Sergios Lenis - email: sergios.lenis@citrix.com - - name: George Nikolopoulos - email: giorgos.nikolopoulos@citrix.com - - name: Shiva Shankar Vaddepally - email: shivashankar.vaddepally@cloud.com + - Sergios Lenis (sergios.lenis@citrix.com) + - George Nikolopoulos (giorgos.nikolopoulos@citrix.com) + - Shiva Shankar Vaddepally (shivashankar.vaddepally@cloud.com) version_added: "2.0.0" options: host: @@ -51,16 +48,12 @@ key: 'host_key_checking' - section: ssh_connection key: 'host_key_checking' - version_added: '2.5' env: - name: ANSIBLE_HOST_KEY_CHECKING - name: ANSIBLE_SSH_HOST_KEY_CHECKING - version_added: '2.5' vars: - name: ansible_host_key_checking - version_added: '2.5' - name: ansible_ssh_host_key_checking - version_added: '2.5' password: description: Authentication password for the C(remote_user). Can be supplied as CLI option. vars: @@ -76,7 +69,6 @@ - name: ANSIBLE_SSHPASS_PROMPT vars: - name: ansible_sshpass_prompt - version_added: "2.0.0" ssh_args: description: Arguments to pass to all ssh cli tools default: '-C -o ControlMaster=auto -o ControlPersist=60s' @@ -87,16 +79,13 @@ - name: ANSIBLE_SSH_ARGS vars: - name: ansible_ssh_args - version_added: "2.0.0" ssh_common_args: description: Common extra args for all ssh CLI tools ini: - section: 'ssh_connection' key: 'ssh_common_args' - version_added: '2.7' env: - name: ANSIBLE_SSH_COMMON_ARGS - version_added: '2.7' vars: - name: ansible_ssh_common_args ssh_executable: @@ -108,11 +97,9 @@ env: [{name: ANSIBLE_SSH_EXECUTABLE}] ini: - {key: ssh_executable, section: ssh_connection} - #const: ANSIBLE_SSH_EXECUTABLE - version_added: "2.2" + version_added: "2.0.0" vars: - name: ansible_ssh_executable - version_added: "2.0.0" sftp_executable: default: sftp description: @@ -120,10 +107,9 @@ env: [{name: ANSIBLE_SFTP_EXECUTABLE}] ini: - {key: sftp_executable, section: ssh_connection} - version_added: "2.6" + version_added: "2.0.0" vars: - name: ansible_sftp_executable - version_added: "2.0.0" scp_executable: default: scp description: @@ -131,45 +117,37 @@ env: [{name: ANSIBLE_SCP_EXECUTABLE}] ini: - {key: scp_executable, section: ssh_connection} - version_added: "2.6" + version_added: "2.0.0" vars: - name: ansible_scp_executable - version_added: "2.0.0" scp_extra_args: description: Extra exclusive to the ``scp`` CLI vars: - name: ansible_scp_extra_args env: - name: ANSIBLE_SCP_EXTRA_ARGS - version_added: "2.0.0" ini: - key: scp_extra_args section: ssh_connection - version_added: "2.0.0" sftp_extra_args: description: Extra exclusive to the ``sftp`` CLI vars: - name: ansible_sftp_extra_args env: - name: ANSIBLE_SFTP_EXTRA_ARGS - version_added: "2.0.0" ini: - key: sftp_extra_args section: ssh_connection - version_added: "2.0.0" ssh_extra_args: description: Extra exclusive to the 'ssh' CLI vars: - name: ansible_ssh_extra_args env: - name: ANSIBLE_SSH_EXTRA_ARGS - version_added: "2.0.0" ini: - key: ssh_extra_args section: ssh_connection - version_added: "2.0.0" retries: - # constant: ANSIBLE_SSH_RETRIES description: Number of attempts to connect. default: 3 type: integer @@ -182,7 +160,6 @@ key: retries vars: - name: ansible_ssh_retries - version_added: "2.0.0" reconnection_retries: description: Number of attempts to connect. default: 0 @@ -196,7 +173,6 @@ key: retries vars: - name: ansible_ssh_retries - version_added: "2.0.0" port: description: Remote port to connect to. type: int @@ -232,12 +208,9 @@ which is why this feature is disabled by default. env: - name: ANSIBLE_PIPELINING - #- name: ANSIBLE_SSH_PIPELINING ini: - section: defaults key: pipelining - #- section: ssh_connection - # key: pipelining type: boolean vars: - name: ansible_pipelining @@ -264,7 +237,6 @@ section: ssh_connection vars: - name: ansible_control_path - version_added: "2.0.0" control_path_dir: default: ~/.ansible/cp description: @@ -277,7 +249,6 @@ key: control_path_dir vars: - name: ansible_control_path_dir - version_added: "2.0.0" sftp_batch_mode: default: 'yes' description: 'TODO: write it' @@ -287,7 +258,6 @@ type: bool vars: - name: ansible_sftp_batch_mode - version_added: "2.0.0" ssh_transfer_method: description: - "Preferred method to use when transferring files over ssh" @@ -308,9 +278,8 @@ - {key: scp_if_ssh, section: ssh_connection} vars: - name: ansible_scp_if_ssh - version_added: "2.0.0" use_tty: - version_added: '2.5' + version_added: '2.0.0' default: 'yes' description: add -tt to ssh commands to force tty allocation env: [{name: ANSIBLE_SSH_USETTY}] @@ -319,7 +288,6 @@ type: bool vars: - name: ansible_ssh_use_tty - version_added: "2.0.0" timeout: default: 10 description: @@ -328,16 +296,13 @@ env: - name: ANSIBLE_TIMEOUT - name: ANSIBLE_SSH_TIMEOUT - version_added: "2.0.0" ini: - key: timeout section: defaults - key: timeout section: ssh_connection - version_added: "2.0.0" vars: - name: ansible_ssh_timeout - version_added: "2.0.0" cli: - name: timeout type: integer @@ -351,7 +316,6 @@ - name: ANSIBLE_PKCS11_PROVIDER vars: - name: ansible_pkcs11_provider - version_added: "2.0.0" ''' import codecs @@ -444,4 +408,4 @@ def _run(self, cmd, in_data, sudoable=True, checkrc=True): def exec_command(self, cmd, in_data=None, sudoable=True): ''' run a command on the remote host ''' - return super(Connection, self).exec_command(cmd, in_data=in_data, sudoable=sudoable) + return super(Connection, self).exec_command(cmd, in_data=in_data, sudoable=sudoable) \ No newline at end of file