From 1ea667426771aa57528f60d939926e323c3667cd Mon Sep 17 00:00:00 2001 From: Cyril Lavier Date: Mon, 15 Jul 2013 09:52:50 +0200 Subject: [PATCH] displaying secondary ip addresses in the ip_interface grain. --- salt/grains/core.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/salt/grains/core.py b/salt/grains/core.py index 32b317a173..b8c8edb5b4 100644 --- a/salt/grains/core.py +++ b/salt/grains/core.py @@ -915,6 +915,9 @@ def ip_interfaces(): for inet in ifaces[face].get('inet', []): if 'address' in inet: iface_ips.append(inet['address']) + for secondary in ifaces[face].get('secondary', []): + if 'address' in secondary: + iface_ips.append(secondary['address']) ret[face] = iface_ips return {'ip_interfaces': ret}