Vagrant Box上的Chef:找不到加密的数据包秘密 [英] Chef on Vagrant Box: Can't find encrypted data bag secret

查看:55
本文介绍了Vagrant Box上的Chef:找不到加密的数据包秘密的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在用(hosted-)chef配置一个无用的框时,出现以下错误:

When provisioning a vagrant box with (hosted-)chef I get the following error:

No such file or directory - file not found '/tmp/encrypted_data_bag_secret'

这是导致错误的调用:

ssl = Chef::EncryptedDataBagItem.load("ssl", s[:id])

我也找不到 / etc / chef中的 encrypted_data_bag_secret 通常位于我的其他服务器上。

I also can't find the encrypted_data_bag_secret in /etc/chef where it normally resides on my other servers.

我错过了上传数据袋秘密的配置吗?

Am I missing a config which uploads the data bag secret?

这是其余的堆栈跟踪信息:

Here's the rest of the stack trace:

[2013-02-14T16:51:15+00:00] ERROR: Running exception handlers
[2013-02-14T16:51:15+00:00] FATAL: Saving node information to /srv/chef/file_store/failed-run-data.json
[2013-02-14T16:51:15+00:00] ERROR: Exception handlers complete
[2013-02-14T16:51:15+00:00] FATAL: Stacktrace dumped to /srv/chef/file_store/chef-stacktrace.out
[2013-02-14T16:51:15+00:00] FATAL: Errno::ENOENT: No such file or directory - file not found '/tmp/encrypted_data_bag_secret'


推荐答案

在配置无用信息框时,如果要使用加密的数据包,则必须提供数据包密钥的路径。

When provisioning a vagrant box, you have to provide a path to your data bags secret key, if you want to use encrypted data bags.

config.vm.provision :chef_solo do |chef|
  [...]
  chef.encrypted_data_bag_secret_key_path = '/etc/chef/encrypted_data_bag_secret'
  [...]
end

这篇关于Vagrant Box上的Chef:找不到加密的数据包秘密的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆