Warning: file_get_contents(/data/phpspider/zhask/data//catemap/5/ruby/25.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Ruby foreman注册傀儡的智能代理错误_Ruby_Puppet_Puppetlabs Apache_Theforeman - Fatal编程技术网

Ruby foreman注册傀儡的智能代理错误

Ruby foreman注册傀儡的智能代理错误,ruby,puppet,puppetlabs-apache,theforeman,Ruby,Puppet,Puppetlabs Apache,Theforeman,我已经在同一个ubuntu 12.x上安装了foreman、foreman proxy和puppet,并尝试添加智能代理条目,但我发现了以下错误,有什么想法吗?我已删除数据库并重新启动,但仍然存在相同的问题 Started POST "/smart_proxies" for 10.10.50.15 at 2014-03-06 15:44:53 -0500 Processing by SmartProxiesController#create as */* Parameters: {"utf8

我已经在同一个ubuntu 12.x上安装了
foreman
foreman proxy
puppet
,并尝试添加
智能代理
条目,但我发现了以下错误,有什么想法吗?我已删除数据库并重新启动,但仍然存在相同的问题

Started POST "/smart_proxies" for 10.10.50.15 at 2014-03-06 15:44:53 -0500
Processing by SmartProxiesController#create as */*
  Parameters: {"utf8"=>"✓", "authenticity_token"=>"NwndUWNHb78ay/6KKVxDMPSb4TLwaPnNr7vMz06JwnU=", "smart_proxy"=>{"name"=>"a", "url"=>"https://spatel-optiplex-755.example.local:8443"}}
Failed to save: 
  Rendered smart_proxies/_form.html.erb (2.0ms)
  Rendered smart_proxies/new.html.erb within layouts/application (2.5ms)
  Rendered home/_user_dropdown.html.erb (1.1ms)
Read fragment views/tabs_and_title_records-1 0.1ms
  Rendered home/_topbar.html.erb (1.8ms)
  Rendered layouts/base.html.erb (3.0ms)
Completed 200 OK in 96.3ms (Views: 6.7ms | ActiveRecord: 0.6ms)

我也有同样的问题,做了一些调查,发现了这段对话:

在我的例子中,似乎默认的foreman代理安装只启用了“事实”功能。出于某种原因,它不足以保存在foreman智能代理列表中。在添加更多功能后,foreman能够使用提供的功能列表保存代理(不包括“事实”)


希望有帮助。

有什么解决方案吗?是的,我安装了两个版本的
json
gem,仔细检查,其中一个似乎安装不正确(例如
32位
版本在
64位
ruby上,或者相反)。还要确保在
setting.yml
中有
:puppet:true
,您添加了哪些“更多功能”?另外,您是否能够保存代理?“排除‘事实’是什么意思?”@PatrickM by features我指的是代理正在公开的功能列表。我通过修改/etc/foreman proxy/settings.d/{puppet.yml,puppetca.yml}和setting:enabled:true添加了puppet和puppetca特性。是的,重新启动代理后,我能够将其保存在foreman应用程序中。当您保存代理时,您会得到它支持的功能列表,在我的例子中,它是puppet和puppetca,而从技术上讲,我的代理支持puppet、puppetca和“事实”(不管它是什么,无论如何都被排除在外)。您可以通过导航到来检查代理支持哪些功能。