diff options
author | Abhijeet Kasurde <akasurde@redhat.com> | 2024-08-02 02:12:57 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-08-02 02:12:57 +0200 |
commit | 91f680a749dfdb3702fee0282587f792de8d6662 (patch) | |
tree | f5b23e14ce7c90f0ca91e1050e1af3161ddcafef | |
parent | Remove EXTERNALLY-MANAGED marker in apt test (#83706) (diff) | |
download | ansible-91f680a749dfdb3702fee0282587f792de8d6662.tar.xz ansible-91f680a749dfdb3702fee0282587f792de8d6662.zip |
Remove extraneous get_bin_path call (#83675)
ip_path is already calculated before calling get_interfaces_info
Signed-off-by: Abhijeet Kasurde <akasurde@redhat.com>
Co-authored-by: Sloane Hertel <19572925+s-hertel@users.noreply.github.com>
Co-authored-by: Brian Coca <bcoca@users.noreply.github.com>
-rw-r--r-- | changelogs/fragments/linux_network_get.yml | 3 | ||||
-rw-r--r-- | lib/ansible/module_utils/facts/network/linux.py | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/changelogs/fragments/linux_network_get.yml b/changelogs/fragments/linux_network_get.yml new file mode 100644 index 0000000000..01af77621d --- /dev/null +++ b/changelogs/fragments/linux_network_get.yml @@ -0,0 +1,3 @@ +--- +bugfixes: + - linux - remove extraneous get_bin_path API call. diff --git a/lib/ansible/module_utils/facts/network/linux.py b/lib/ansible/module_utils/facts/network/linux.py index 560cd255f3..d199d5a6ae 100644 --- a/lib/ansible/module_utils/facts/network/linux.py +++ b/lib/ansible/module_utils/facts/network/linux.py @@ -295,8 +295,6 @@ class LinuxNetwork(Network): if not address == '::1': ips['all_ipv6_addresses'].append(address) - ip_path = self.module.get_bin_path("ip") - args = [ip_path, 'addr', 'show', 'primary', 'dev', device] rc, primary_data, stderr = self.module.run_command(args, errors='surrogate_then_replace') if rc == 0: |