mirror of
https://github.com/ansible/ansible.git
synced 2026-07-28 16:15:12 +02:00
Fix ansible-test remote aliases for new-style args (#86844)
* Always include `name` when applying remote config defaults for Posix/Windows.
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
bugfixes:
|
||||
- ansible-test remote alias - Alias values for ``--controller`` and ``--target`` are properly resolved for ``remote``.
|
||||
Previously, remote alias values (e.g. ``fedora/latest``) resolved to the correct name only for the legacy ``--remote`` arg, failing with an unknown image error for the newer args.
|
||||
@@ -420,6 +420,7 @@ class PosixRemoteConfig(RemoteConfig, ControllerHostConfig, PosixConfig):
|
||||
super().apply_defaults(context, defaults)
|
||||
|
||||
self.become = self.become or defaults.become
|
||||
self.name = defaults.name
|
||||
|
||||
@property
|
||||
def have_root(self) -> bool:
|
||||
@@ -450,6 +451,7 @@ class WindowsRemoteConfig(RemoteConfig, WindowsConfig):
|
||||
super().apply_defaults(context, defaults)
|
||||
|
||||
self.connection = self.connection or defaults.connection
|
||||
self.name = defaults.name
|
||||
|
||||
|
||||
@dataclasses.dataclass
|
||||
|
||||
Reference in New Issue
Block a user