diff --git a/changelogs/fragments/ssh_args.yaml b/changelogs/fragments/ssh_args.yaml
new file mode 100644
index 000000000..a25f0821b
--- /dev/null
+++ b/changelogs/fragments/ssh_args.yaml
@@ -0,0 +1,3 @@
+---
+deprecated_features:
+ - The ssh_*_args options are now marked that they will be removed after 2026-01-01.
diff --git a/docs/ansible.netcommon.libssh_connection.rst b/docs/ansible.netcommon.libssh_connection.rst
index 513cd2276..42a5b4628 100644
--- a/docs/ansible.netcommon.libssh_connection.rst
+++ b/docs/ansible.netcommon.libssh_connection.rst
@@ -291,7 +291,7 @@ Parameters
Arguments to pass to all ssh CLI tools.
ProxyCommand is the only supported argument.
- This option is deprecated in favor of proxy_command.
+ This option is deprecated in favor of proxy_command and will be removed in a release after 2026-01-01.
|
@@ -316,7 +316,7 @@ Parameters
Common extra arguments for all ssh CLI tools.
ProxyCommand is the only supported argument.
- This option is deprecated in favor of proxy_command.
+ This option is deprecated in favor of proxy_command and will be removed in a release after 2026-01-01.
|
@@ -341,7 +341,7 @@ Parameters
Extra arguments exclusive to the 'ssh' CLI tool.
ProxyCommand is the only supported argument.
- This option is deprecated in favor of proxy_command.
+ This option is deprecated in favor of proxy_command and will be removed in a release after 2026-01-01.
|
diff --git a/plugins/connection/libssh.py b/plugins/connection/libssh.py
index e76d25a94..a9ff73f5f 100644
--- a/plugins/connection/libssh.py
+++ b/plugins/connection/libssh.py
@@ -130,7 +130,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'
@@ -146,7 +147,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'
@@ -162,7 +164,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
@@ -314,6 +317,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":