Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

set puppet config variables AFTER parse_config

fixes the case, where manifest gets set to a bad value in puppet.conf
noticed by Oliver Hookins
  • Loading branch information...
commit d1dc98c86fee8759d568473ed4ce494474138cd6 1 parent 0448454
Nikolay Sturm nistude authored
Showing with 4 additions and 2 deletions.
  1. +4 −2 lib/cucumber-puppet/puppet.rb
6 lib/cucumber-puppet/puppet.rb
View
@@ -41,9 +41,11 @@ def klass=(klass)
# @manifest defaults to @confdir + '/manifests/site.pp'
#
def compile_catalog( node = nil )
- Puppet[:confdir] = @confdir
- Puppet[:manifest] = @manifest
+ Puppet.settings.handlearg("--confdir", @confdir)
Puppet.parse_config
+ # reset confdir in case it got overwritten
+ Puppet.settings.handlearg("--confdir", @confdir)
+ Puppet.settings.handlearg("--manifest", @manifest)
unless node.is_a?(Puppet::Node)
node = Puppet::Node.new(@facts['hostname'], :classes => @klass)
Please sign in to comment.
Something went wrong with that request. Please try again.