From: Peter Palfrader Date: Sun, 15 Sep 2019 16:20:25 +0000 (+0200) Subject: Get this hosts public IP address for the apache allow rather than going via roles X-Git-Url: https://git.adam-barratt.org.uk/?a=commitdiff_plain;h=f0dbdd268d1206dfd4f0c4c848758089654ed135;p=mirror%2Fdsa-puppet.git Get this hosts public IP address for the apache allow rather than going via roles --- diff --git a/modules/roles/templates/planet_master/planet-master.debian.org.erb b/modules/roles/templates/planet_master/planet-master.debian.org.erb index e8a7d474c..fc644c932 100644 --- a/modules/roles/templates/planet_master/planet-master.debian.org.erb +++ b/modules/roles/templates/planet_master/planet-master.debian.org.erb @@ -25,12 +25,8 @@ Use common-debian-service-https-redirect * planet-master.debian.org Require ip 127.0.0.1 <%= lines = [] - roles = scope.lookupvar('deprecated::roles') - roles['planet_master'].each do |node| - lines << "\t\t# #{scope.lookupvar('deprecated::allnodeinfo')[node]['hostname'][0]}" - scope.lookupvar('deprecated::allnodeinfo')[node]['ipHostNumber'].each do |addr| - lines << "\t\tRequire ip #{addr}" - end + scope.lookupvar('base::public_addresses').each do |addr| + lines << "\t\tRequire ip #{addr}" end lines.join("\n") # vim:set et: