Skip to content

Commit

Permalink
Indicate that ssh_args will be removed.
Browse files Browse the repository at this point in the history
  • Loading branch information
Qalthos committed Jul 31, 2023
1 parent 07ef0c5 commit 32a1386
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 6 deletions.
3 changes: 3 additions & 0 deletions changelogs/fragments/ssh_args.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
deprecated_features:
- The ssh_*_args options are now marked that they will be removed after 2026-01-01.
6 changes: 3 additions & 3 deletions docs/ansible.netcommon.libssh_connection.rst
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ Parameters
<td>
<div>Arguments to pass to all ssh CLI tools.</div>
<div>ProxyCommand is the only supported argument.</div>
<div>This option is deprecated in favor of <em>proxy_command</em>.</div>
<div>This option is deprecated in favor of <em>proxy_command</em> and will be removed in a release after 2026-01-01.</div>
</td>
</tr>
<tr>
Expand All @@ -316,7 +316,7 @@ Parameters
<td>
<div>Common extra arguments for all ssh CLI tools.</div>
<div>ProxyCommand is the only supported argument.</div>
<div>This option is deprecated in favor of <em>proxy_command</em>.</div>
<div>This option is deprecated in favor of <em>proxy_command</em> and will be removed in a release after 2026-01-01.</div>
</td>
</tr>
<tr>
Expand All @@ -341,7 +341,7 @@ Parameters
<td>
<div>Extra arguments exclusive to the &#x27;ssh&#x27; CLI tool.</div>
<div>ProxyCommand is the only supported argument.</div>
<div>This option is deprecated in favor of <em>proxy_command</em>.</div>
<div>This option is deprecated in favor of <em>proxy_command</em> and will be removed in a release after 2026-01-01.</div>
</td>
</tr>
<tr>
Expand Down
12 changes: 9 additions & 3 deletions plugins/connection/libssh.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,8 @@
description:
- Arguments to pass to all ssh CLI tools.
- ProxyCommand is the only supported argument.
- This option is deprecated in favor of I(proxy_command).
- This option is deprecated in favor of I(proxy_command) and will be removed
in a release after 2026-01-01.
type: string
ini:
- section: 'ssh_connection'
Expand All @@ -147,7 +148,8 @@
description:
- Common extra arguments for all ssh CLI tools.
- ProxyCommand is the only supported argument.
- This option is deprecated in favor of I(proxy_command).
- This option is deprecated in favor of I(proxy_command) and will be removed
in a release after 2026-01-01.
type: string
ini:
- section: 'ssh_connection'
Expand All @@ -163,7 +165,8 @@
description:
- Extra arguments exclusive to the 'ssh' CLI tool.
- ProxyCommand is the only supported argument.
- This option is deprecated in favor of I(proxy_command).
- This option is deprecated in favor of I(proxy_command) and will be removed
in a release after 2026-01-01.
type: string
vars:
- name: ansible_ssh_extra_args
Expand Down Expand Up @@ -318,6 +321,9 @@ def _get_proxy_command(self, port=22):
]

if any(ssh_args):
display.warning(
"The ssh_*_args options are deprecated and will be removed in a release after 2026-01-01. Please use the proxy_command option instead."
)
args = self._split_ssh_args(" ".join(ssh_args))
for i, arg in enumerate(args):
if arg.lower() == "proxycommand":
Expand Down

0 comments on commit 32a1386

Please sign in to comment.