Issue #10651 has been updated by Nigel Kersten.

+Nick, Randall

I'd be interested in both your views on this request. Nick, could you document 
and explain this easily? Randall, is this a good idea from a UX perspective?

I'm not particularly in favor of this. It's not that I'm unsympathetic to the 
need, but I feel like we have enough magical implicit behavior in our config 
files, and that we generally need to wind back to much more explicit behavior.
----------------------------------------
Feature #10651: Allow the default modulepath in puppet.config to be augmented
https://projects.puppetlabs.com/issues/10651

Author: Ian Brandt
Status: Needs Decision
Priority: Normal
Assignee: Nigel Kersten
Category: 
Target version: 
Affected Puppet version: 2.7.6
Keywords: 
Branch: 


With my puppet.config as follows:

    [main]
    modulepath = $modulepath:/my/module/path

I find `:/my/module/path` is simply dropped:

    $ puppet apply -e 'notice("$settings::modulepath")'
    notice: Scope(Class[main]): 
/Users/ibrandt/.puppet/modules:/usr/share/puppet/modules
    notice: Finished catalog run in 0.02 seconds

I've tried several variations:

    [main]
    modulepath = ${modulepath}:/my/module/path

...

    $ puppet apply -e 'notice("$settings::modulepath")'
    err: Could not parse /Users/ibrandt/.puppet/puppet.conf: Could not parse 
'${modulepath}:/my/module/path'
    notice: Scope(Class[main]): 
/Users/ibrandt/.puppet/modules:/usr/share/puppet/modules
    notice: Finished catalog run in 0.02 seconds

And:

    [main]
    modulepath = ${settings::modulepath}:/my/module/path

...

    $ puppet apply -e 'notice("$settings::modulepath")'
    err: Could not parse /Users/ibrandt/.puppet/puppet.conf: Could not parse 
'${settings::modulepath}:/my/module/path'
    notice: Scope(Class[main]): 
/Users/ibrandt/.puppet/modules:/usr/share/puppet/modules
    notice: Finished catalog run in 0.02 seconds

And:

    [main]
    modulepath = $settings::modulepath:/my/module/path

...

    $ puppet apply -e 'notice("$settings::modulepath")'
    Could not prepare for execution: Could not find value for $settings

And:

    [main]
    modulepath = /my/module/path:${modulepath}

...

    $ puppet apply -e 'notice("$settings::modulepath")'
    err: Could not parse /Users/ibrandt/.puppet/puppet.conf: Could not parse 
'/my/module/path:${modulepath}'
    notice: Scope(Class[main]): 
/Users/ibrandt/.puppet/modules:/usr/share/puppet/modules
    notice: Finished catalog run in 0.02 seconds

And:

    [main]
    modulepath = /my/module/path:$modulepath

...

    $ puppet apply -e 'notice("$settings::modulepath")'
    /Users/ibrandt/.rvm/rubies/ruby-1.8.7-p352/lib/ruby/1.8/sync.rb:214:in 
`sync_unlock': stack level too deep (SystemStackError)
    from /Users/ibrandt/.rvm/rubies/ruby-1.8.7-p352/lib/ruby/1.8/sync.rb:232:in 
`synchronize'
    from 
/Users/ibrandt/.rvm/gems/ruby-1.8.7-p352@etp/gems/puppet-2.7.6/lib/puppet/util/settings.rb:661:in
 `uninterpolated_value'
    from 
/Users/ibrandt/.rvm/gems/ruby-1.8.7-p352@etp/gems/puppet-2.7.6/lib/puppet/util/settings.rb:811:in
 `each_source'
    from 
/Users/ibrandt/.rvm/gems/ruby-1.8.7-p352@etp/gems/puppet-2.7.6/lib/puppet/util/settings.rb:808:in
 `each'
    from 
/Users/ibrandt/.rvm/gems/ruby-1.8.7-p352@etp/gems/puppet-2.7.6/lib/puppet/util/settings.rb:808:in
 `each_source'
    from 
/Users/ibrandt/.rvm/gems/ruby-1.8.7-p352@etp/gems/puppet-2.7.6/lib/puppet/util/settings.rb:658:in
 `uninterpolated_value'
    from 
/Users/ibrandt/.rvm/gems/ruby-1.8.7-p352@etp/gems/puppet-2.7.6/lib/puppet/util/settings.rb:657:in
 `catch'
    from 
/Users/ibrandt/.rvm/gems/ruby-1.8.7-p352@etp/gems/puppet-2.7.6/lib/puppet/util/settings.rb:657:in
 `uninterpolated_value'
    ... 2790 levels...
    from 
/Users/ibrandt/.rvm/gems/ruby-1.8.7-p352@etp/gems/puppet-2.7.6/lib/puppet/util/command_line.rb:69:in
 `execute'
    from 
/Users/ibrandt/.rvm/gems/ruby-1.8.7-p352@etp/gems/puppet-2.7.6/bin/puppet:4
    from /Users/ibrandt/.rvm/gems/ruby-1.8.7-p352@etp/bin/puppet:19:in `load'
    from /Users/ibrandt/.rvm/gems/ruby-1.8.7-p352@etp/bin/puppet:19
    
And:

    [main]
    defaultmodulepath = $modulepath
    modulepath = $defaultmodulepath:/my/module/path

...

    $ puppet apply -e 'notice("$settings::modulepath")'
    Could not prepare for execution: Could not find value for $defaultmodulepath



-- 
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://projects.puppetlabs.com/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.

Reply via email to