我有一个问题让木偶工作。我正在使用OpenSUSE 13.2,我的ruby版本是2.1.3p242,木偶版本是3.7.1。
我得到site.pp
来测试木偶:
node default {
file { '/tmp/depl_mon.sql':
ensure => file,
content => 'CREATE TABLE if not exists hash_key (id varchar(64) NOT NULL, PRIMARY KEY (id));',
}
}
以下是我运行puppet apply site.pp --trace --debug
时出现的错误:
Debug: Runtime environment: puppet_version=3.7.1, ruby_version=2.1.3, run_mode=user, default_encoding=UTF-8
Error: wrong number of arguments (2 for 1)
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/parser/compiler.rb:19:in `compile'
/usr/lib64/ruby/gems/2.1.0/gems/puppet-4.3.0/lib/puppet/indirector/catalog/compiler.rb:93:in `block (2 levels) in compile'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/util/profiler/around_profiler.rb:58:in `profile'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/util/profiler.rb:51:in `profile'
/usr/lib64/ruby/gems/2.1.0/gems/puppet-4.3.0/lib/puppet/indirector/catalog/compiler.rb:91:in `block in compile'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/util.rb:161:in `block in benchmark'
/usr/lib64/ruby/2.1.0/benchmark.rb:294:in `realtime'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/util.rb:160:in `benchmark'
/usr/lib64/ruby/gems/2.1.0/gems/puppet-4.3.0/lib/puppet/indirector/catalog/compiler.rb:90:in `compile'
/usr/lib64/ruby/gems/2.1.0/gems/puppet-4.3.0/lib/puppet/indirector/catalog/compiler.rb:50:in `find'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/indirector/indirection.rb:201:in `find'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/application/apply.rb:217:in `block in main'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/context.rb:64:in `override'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet.rb:244:in `override'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/application/apply.rb:193:in `main'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/application/apply.rb:154:in `run_command'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/application.rb:384:in `block (2 levels) in run'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/application.rb:510:in `plugin_hook'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/application.rb:384:in `block in run'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/util.rb:488:in `exit_on_fail'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/application.rb:384:in `run'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/util/command_line.rb:146:in `run'
/usr/lib64/ruby/vendor_ruby/2.1.0/puppet/util/command_line.rb:92:in `execute'
/usr/bin/puppet:8:in `<main>'