Global variable not puppulated ont he first run after server build

asked 2015-11-03 12:08:33 -0600

polasekr gravatar image

updated 2015-11-04 15:33:14 -0600

GregLarkin gravatar image

We are using Puppet server built into Redhat satellite server 6.1. I have following code (see below) that uses PuppetGroup variable defined as a global variable in Redhat satellite 6 server. We run on the client Puppet v3.6.2. I inserted function notify to show me value of variable PuppetGroup. When the puppet code is run for the first time after server build, the variable has no value. Any subsequent run, without any changes to the code, correctly reports PuppetGroup variable value.

Can somebody point me in a right direction, how to fix the issue. Your help is appreciated.

class configure::dnsresolvconf {
  if  defined ("configure::dnsresolvconf::${puppetgroup}"){
    configure::trace { "Class configure::dnsresolvconf::${puppetgroup} is being executed": }
    include "configure::dnsresolvconf::${puppetgroup}"
  } else {
    configure::trace { "Class configure::dnsresolvconf::${puppetgroup} is not defined": }

edit retag flag offensive close merge delete