From: Peter Palfrader Date: Sat, 7 Sep 2019 23:13:59 +0000 (+0200) Subject: base::public_addresses: handle v4 only hosts like fasolo X-Git-Url: https://git.adam-barratt.org.uk/?a=commitdiff_plain;h=9f4edb3c5b6c660d480a48c24f718d31b93f14f8;p=mirror%2Fdsa-puppet.git base::public_addresses: handle v4 only hosts like fasolo --- diff --git a/modules/base/manifests/init.pp b/modules/base/manifests/init.pp index bda0d7f30..5f3b31802 100644 --- a/modules/base/manifests/init.pp +++ b/modules/base/manifests/init.pp @@ -2,5 +2,5 @@ class base( Stdlib::IP::Address $public_address = filter_ipv4(getfromhash($site::nodeinfo, 'ldap', 'ipHostNumber'))[0], Optional[Stdlib::IP::Address] $public_address6 = filter_ipv6(getfromhash($site::nodeinfo, 'ldap', 'ipHostNumber'))[0], ) { - $public_addresses = [ $public_address, $public_address6 ] + $public_addresses = [ $public_address, $public_address6 ].filter |$addr| { $addr != undef } }