Issue #1175 has been updated by luke.
I've figured out how to solve half of this problem: The functions should get added to a module, and then that module should get included into each Scope. This provides the environment-specific collection. There's more to it than that, though -- the loader needs to work in multiple environments, and we need some way to tell the function which environment it belongs in (it obviously can't be declared as part of the function declaration). ---------------------------------------- Bug #1175: Custom function doesn't work when using multiple environments http://projects.reductivelabs.com:80/issues/1175 Author: eugene Status: Accepted Priority: High Assigned to: luke Category: language Target version: unplanned Complexity: Medium Patch: None Affected version: 0.22.1 Keywords: Environments settings in @puppet.conf@: client: <pre> [main] environment = production </pre> server: <pre> [main] environments = production,development [production] manifest = /usr/local/etc/puppet/manifests/production/site.pp modulepath = /usr/local/etc/puppet/modules/production </pre> I have module for postfix configuration with custom function My postfix module located in @/usr/local/etc/puppet/modules/production/postfix@ and my custom function in @/usr/local/etc/puppet/modules/production/postfix/plugins/puppet/parser/functi...@. I get the following error running puppet client: <pre> err: Could not retrieve catalog: Unknown function .... at /usr/local/etc/puppet/modules/production/postfix/manifests/init.pp:60 on node ..... </pre> If I disable using this function in @postfix/manifests/init.pp@ module works. If I use setup without environments with configuration: <pre> [main] manifest = /usr/local/etc/puppet/manifests/site.pp modulepath = /usr/local/etc/puppet/modules </pre> and place module into @/usr/local/etc/puppet/modules/postfix@ and function into @/usr/local/etc/puppet/modules/postfix/plugins/puppet/parser/functions@ everything works as expected. os version: [[FreeBSD]]-6.2 puppet version: 0.24.4 ---------------------------------------- You have received this notification because you have either subscribed to it, or are involved in it. To change your notification preferences, please click here: http://reductivelabs.com/redmine/my/account --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
