Now that we have site included before hiera things, we can do this again
authorPeter Palfrader <peter@palfrader.org>
Fri, 30 Aug 2019 10:20:18 +0000 (12:20 +0200)
committerPeter Palfrader <peter@palfrader.org>
Fri, 30 Aug 2019 10:20:18 +0000 (12:20 +0200)
modules/profile/manifests/ipsec/fasolo_storace.pp

index b2d9153..9cc8340 100644 (file)
@@ -5,8 +5,7 @@ class profile::ipsec::fasolo_storace {
   # Use the first ipv4 address from LDAP, since the puppet fact is not always
   # the IP address we want to use.  For instance, for storace $::facts['ipaddress']
   # is 172.29.170.1 (from bond1) instead of 93.94.130.161 from eth0.
-  $public_ipaddresses = getfromhash($site::nodeinfo, 'misc', 'v4_ldap')
-  $public_ipaddress = public_ipaddresses[0]
+  $public_ipaddress = getfromhash($site::nodeinfo, 'misc', 'v4_ldap')[0]
 
   # we do ipsec on the backend since it traveres over other people's switching infra
   ipsec::network { "fasolo_storace":