#1157: 0.24.4rc1: resources inside of @@defines are not being created nor
exported
---------------------------------------------+------------------------------
Reporter: Fujin | Owner: community
Type: defect | Status: new
Priority: normal | Component: library
Version: 0.24.3 | Severity: normal
Keywords: resources virtual defines export | Stage: Unreviewed
Patch: None | Complexity: Unknown
---------------------------------------------+------------------------------
{{{
# ntp module
class blah {
@@concatenatedfilepart {
# export this server for our own clients
"server_${fqdn}":
dir => "/var/lib/puppet/modules/ntp/ntp.client.d",
content => "server ${fqdn} iburst\n",
tag => 'ntp';
# export this server for our other servers
"peer_${fqdn}":
dir => "/var/lib/puppet/modules/ntp/ntp.server.d",
content => "peer ${fqdn} iburst\nrestrict ${fqdn} nomodify
notrap\n",
tag => 'ntp';
}
}
define concatenatedfilepart (
$dir, $content = '', $ensure = present,
$mode = 0644, $owner = root, $group = root
)
{
file { "${dir}/${name}":
ensure => $ensure, content => $content,
mode => $mode, owner => $owner, group => $group,
alias => "cf_part_${name}",
notify => Exec["concat_${dir}"],
require => File["${dir}"];
}
}
}
}}}
MySQL DB looks like this. Note that the define is actually being exported,
not the file resources as expected:
{{{
mysql> select * from resources where title not like '%munin%' and exported
is not null\G
*************************** 1. row ***************************
id: 14773
title: peer_smtp02.maxnet.net.nz
restype: Ntp::Concatenatedfilepart
host_id: 29
source_file_id: 10
exported: 1
line: 85
updated_at: 2008-03-26 01:06:36
*************************** 2. row ***************************
id: 14800
title: server_smtp02.maxnet.net.nz
restype: Ntp::Concatenatedfilepart
host_id: 29
source_file_id: 10
exported: 1
line: 85
updated_at: 2008-03-26 01:06:46
*************************** 3. row ***************************
id: 14813
title: server_smtp01.maxnet.net.nz
restype: Ntp::Concatenatedfilepart
host_id: 28
source_file_id: 10
exported: 1
line: 85
updated_at: 2008-03-26 01:06:50
*************************** 4. row ***************************
id: 14895
title: peer_smtp01.maxnet.net.nz
restype: Ntp::Concatenatedfilepart
host_id: 28
source_file_id: 10
exported: 1
line: 85
updated_at: 2008-03-26 01:07:04
4 rows in set (0.00 sec)
}}}
--
Ticket URL: <http://reductivelabs.com/trac/puppet/ticket/1157>
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
-~----------~----~----~----~------~----~------~--~---