Last active
December 30, 2015 11:09
-
-
Save fatmcgav/7821149 to your computer and use it in GitHub Desktop.
rspec-puppet failure point
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Failure/Error: it { should_not contain_class('act::software::hp::psp') } | |
Puppet::Error: | |
Puppet::Parser::AST::Resource failed with error TypeError: can't convert Hash into String at /etc/puppet/environments/common/act/spec/fixtures/modules/act/manifests/software/linux/puppet_agent.pp:27 on node puppet-dev.card.co.uk | |
# /usr/lib/ruby/site_ruby/1.8/puppet/indirector/hiera.rb:21:in `exist?' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/indirector/hiera.rb:21:in `hiera_config' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/indirector/hiera.rb:32:in `hiera' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/indirector/hiera.rb:36:in `hiera' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/indirector/hiera.rb:12:in `find' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/indirector/indirection.rb:197:in `find' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/resource.rb:331:in `lookup_external_default_for' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/resource.rb:350:in `set_default_parameters' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/resource.rb:349:in `collect' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/resource.rb:349:in `set_default_parameters' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/resource/type.rb:299:in `set_resource_parameters' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/resource/type.rb:107:in `evaluate_code' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/resource.rb:81:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/compiler.rb:185:in `evaluate_classes' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/compiler.rb:170:in `each' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/compiler.rb:170:in `evaluate_classes' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/resource.rb:60:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/util/errors.rb:62:in `exceptwrap' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/resource.rb:43:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/resource.rb:42:in `collect' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/resource.rb:42:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in `collect' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/branch.rb:12:in `each' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/branch.rb:11:in `each' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/resource.rb:25:in `collect' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/resource.rb:25:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast.rb:62:in `safeevaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/block_expression.rb:15:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/block_expression.rb:10:in `each' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/block_expression.rb:10:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast.rb:62:in `safeevaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/resource/type.rb:121:in `evaluate_code' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/resource.rb:81:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/compiler.rb:185:in `evaluate_classes' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/compiler.rb:170:in `each' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/compiler.rb:170:in `evaluate_classes' | |
# /usr/lib/ruby/gems/1.8/gems/puppet-3.3.2/lib/puppet/parser/functions/include.rb:11:in `real_function_include' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/functions.rb:147:in `send' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/functions.rb:147:in `function_include' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/util/profiler/none.rb:6:in `profile' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/util/profiler.rb:26:in `profile' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/functions.rb:140:in `function_include' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/function.rb:42:in `send' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/function.rb:42:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast.rb:62:in `safeevaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/block_expression.rb:15:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/block_expression.rb:10:in `each' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/block_expression.rb:10:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast.rb:62:in `safeevaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/ifstatement.rb:25:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast.rb:62:in `safeevaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/block_expression.rb:15:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/block_expression.rb:10:in `each' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/block_expression.rb:10:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast.rb:62:in `safeevaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/resource/type.rb:121:in `evaluate_code' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/resource.rb:81:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/compiler.rb:185:in `evaluate_classes' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/compiler.rb:170:in `each' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/compiler.rb:170:in `evaluate_classes' | |
# /usr/lib/ruby/gems/1.8/gems/puppet-3.3.2/lib/puppet/parser/functions/include.rb:11:in `real_function_include' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/functions.rb:147:in `send' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/functions.rb:147:in `function_include' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/util/profiler/none.rb:6:in `profile' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/util/profiler.rb:26:in `profile' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/functions.rb:140:in `function_include' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/function.rb:42:in `send' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/function.rb:42:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast.rb:62:in `safeevaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/block_expression.rb:15:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/block_expression.rb:10:in `each' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast/block_expression.rb:10:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/ast.rb:62:in `safeevaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/resource/type.rb:121:in `evaluate_code' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/resource.rb:81:in `evaluate' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/compiler.rb:353:in `evaluate_main' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/compiler.rb:116:in `compile_unadorned' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/util/profiler/none.rb:6:in `profile' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/util/profiler.rb:26:in `profile' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/compiler.rb:116:in `compile_unadorned' | |
# /usr/lib/ruby/gems/1.8/gems/hiera-puppet-helper-1.0.1/lib/hiera-puppet-helper/puppet.rb:16:in `compile' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/parser/compiler.rb:29:in `compile' | |
# /usr/lib/ruby/gems/1.8/gems/puppet-3.3.2/lib/puppet/indirector/catalog/compiler.rb:88:in `compile' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/util/profiler/none.rb:6:in `profile' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/util/profiler.rb:26:in `profile' | |
# /usr/lib/ruby/gems/1.8/gems/puppet-3.3.2/lib/puppet/indirector/catalog/compiler.rb:86:in `compile' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/util.rb:182:in `benchmark' | |
# /usr/lib/ruby/1.8/benchmark.rb:308:in `realtime' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/util.rb:181:in `benchmark' | |
# /usr/lib/ruby/gems/1.8/gems/puppet-3.3.2/lib/puppet/indirector/catalog/compiler.rb:85:in `compile' | |
# /usr/lib/ruby/gems/1.8/gems/puppet-3.3.2/lib/puppet/indirector/catalog/compiler.rb:45:in `find' | |
# /usr/lib/ruby/site_ruby/1.8/puppet/indirector/indirection.rb:197:in `find' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-puppet-1.0.1/lib/rspec-puppet/support.rb:141:in `build_catalog_without_cache' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-puppet-1.0.1/lib/rspec-puppet/support.rb:150:in `build_catalog' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-puppet-1.0.1/lib/rspec-puppet/support.rb:12:in `catalogue' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-puppet-1.0.1/lib/rspec-puppet/example/class_example_group.rb:7:in `subject' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/memoized_helpers.rb:82:in `should_not' | |
# ./spec/classes/server/linux_spec.rb:115 | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/example.rb:114:in `instance_eval' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/example.rb:114:in `run' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/example.rb:254:in `with_around_each_hooks' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/example.rb:111:in `run' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/example_group.rb:390:in `run_examples' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/example_group.rb:386:in `map' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/example_group.rb:386:in `run_examples' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/example_group.rb:371:in `run' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/example_group.rb:372:in `run' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/example_group.rb:372:in `map' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/example_group.rb:372:in `run' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/command_line.rb:28:in `run' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/command_line.rb:28:in `map' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/command_line.rb:28:in `run' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/reporter.rb:58:in `report' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/command_line.rb:25:in `run' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/runner.rb:80:in `run' | |
# /usr/lib/ruby/gems/1.8/gems/rspec-core-2.14.7/lib/rspec/core/runner.rb:17:in `autorun' | |
# /usr/bin/rspec:19 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Hieradata shared_context | |
fixture_path = File.expand_path(File.join(__FILE__, '..', '..', 'fixtures')) | |
shared_context 'hieradata' do | |
let(:hiera_config) do | |
{ :backends => ['rspec', 'yaml'], | |
:hierarchy => [ | |
'%{fqdn}/%{calling_module}', | |
'%{calling_module}', | |
'default'], | |
:yaml => { | |
:datadir => File.join(fixture_path, 'hieradata') }, | |
:rspec => respond_to?(:hiera_data) ? hiera_data : {} } | |
end | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Class: act::software::linux::puppet_agent | |
# | |
# This module manages ACT Linux Puppet Agent installation | |
# and configuration | |
# | |
# Parameters: | |
# | |
# Actions: | |
# | |
# Requires: | |
# | |
# Sample Usage: | |
# | |
class act::software::linux::puppet_agent { | |
# Setup puppet for agent | |
sudo::conf { 'puppet': | |
priority => 20, | |
content => "# Puppet user sudo config.\n puppet ALL = NOPASSWD: /usr/bin/puppet agent *\n Defaults:puppet !requiretty", | |
} | |
# Install and configure puppet | |
class { '::puppet': | |
splay => true, | |
runinterval => 1800 | |
# #show_diff => true | |
# version => '3.1.0' | |
} | |
# Tweak puppet var folder permissions | |
file { '/var/lib/puppet': | |
mode => '0755', | |
require => Class['::puppet'] | |
} | |
# Install mcollective | |
#class { '::mcollective': | |
# version => 'present', | |
# server => true, | |
# stomp_server => hiera('stomp_server'), | |
# client => false, | |
# require => Class['::puppet'] | |
#} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment