Actions
Bug #4357
closedUse of Puppet::Node::Environment.current in template headers breaks on Puppet 3.5/master
Description
e.g. /usr/share/foreman-installer/modules/foreman/templates/_header.erb
module_paths = Puppet::Node::Environment.current[:modulepath].split(':').map{|i| File.expand_path(i) }.join('|')
Produces this error:
[ERROR 2014-02-17 12:45:01 main] Failed to parse template foreman/settings.yaml.erb:
[ INFO 2014-02-17 12:45:01 main] Filepath: (erb)
[ INFO 2014-02-17 12:45:01 main] Line: 4
[ INFO 2014-02-17 12:45:01 main] Detail: undefined method `current' for Puppet::Node::Environment:Class
[ INFO 2014-02-17 12:45:01 main] at /usr/share/foreman-installer/modules/foreman/manifests/config.pp:8 on node foreman-el6.example.com
Affected paths:
- /usr/share/foreman-installer/modules/foreman/templates/_header.erb
- /usr/share/foreman-installer/modules/foreman_proxy/templates/settings.yml.erb
- /usr/share/foreman-installer/modules/puppet/templates/_header.erb
- /usr/share/foreman-installer/modules/puppet/templates/agent/puppet.conf.erb
- /usr/share/foreman-installer/modules/puppet/templates/server/config.ru.erb
- /usr/share/foreman-installer/modules/puppet/templates/server/puppet.conf.erb
Actions