From: Luca Filipozzi Date: Wed, 16 May 2012 18:16:19 +0000 (+0000) Subject: scope.hiera() X-Git-Url: https://wiki.adam-barratt.org.uk/gitweb/?a=commitdiff_plain;h=de8a6a46e91e3bb9af8ba0cdef5af85eea29e89a;p=mirror%2Fdsa-puppet.git scope.hiera() --- diff --git a/modules/motd/templates/motd.erb b/modules/motd/templates/motd.erb index 9f9db8cb4..1a3bf1988 100644 --- a/modules/motd/templates/motd.erb +++ b/modules/motd/templates/motd.erb @@ -100,11 +100,9 @@ unless vms.empty? end -Puppet::Parser::Functions.function(:hiera) -Puppet::Parser::Functions.function(:hiera_array) -if hiera('cluster') +if scope.hiera('cluster') purp += "\nganeti cluster: " + hiera('cluster') + " contains these nodes:\n" - hiera_array('nodes').each do |node| + scope.hiera_array('nodes').each do |node| purp += "\t" + node if node.eql?(fqdn) purp += " (this system)"