#1108: variables become undefined on second puppetd run
---------------------+------------------------------------------------------
Reporter: jeffl | Owner: community
Type: defect | Status: new
Priority: normal | Milestone:
Component: library | Version:
Severity: normal | Resolution:
Keywords: | Stage: Needs more info
Patch: None | Complexity: Unknown
---------------------+------------------------------------------------------
Comment (by jeffl):
The gist of the problem is that global variables defined in
modules/mod_name/manifests/init.pp are not made available to the
puppetmaster the first time the file is parsed. It is available the next
time the file is parsed.
So, if I have modules/ntp/manifests/init.pp:
{{{
$ntpserver = 'north-america.pool.ntp.org'
class ntp {
file { '/etc/ntpd.conf':
content => template('ntp/ntp.conf.erb'),
}
}
}}}
The first time I run this class on any client the variable $ntpserver will
be undefined. The very next time this class is used on any client,
$ntpserver will be defined with the correct value.
--
Ticket URL: <http://reductivelabs.com/trac/puppet/ticket/1108#comment:4>
puppet <http://reductivelabs.com>
Puppet - Portable System Automation
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Puppet Bugs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/puppet-bugs?hl=en
-~----------~----~----~----~------~----~------~--~---