ruby - EncryptedDataBagItem.load produces 'cannot convert nil into String' -


i'm following method described in this post creating dns record new server chef provisions it. i've created encrypted data bag item aws credentials:

$ knife data bag show passwords aws --secret-file .chef/encryted_data_bag_secret  aws_access_key: <my_access_key> aws_secret_key: <my_secret_key> id:             aws 

however, when run chef client, line...

aws_creds = chef::encrypteddatabagitem.load('passwords', 'aws') 

produces error:

typeerror: can't convert nil string 

i've tried searching error, while can see evidence other people have encountered this, it's not clear problem or how resolved. what's going on here, , how can fix it?

i hit error today too. me, node missing encrypted_data_bag_secret.

according bug (http://tickets.opscode.com/browse/chef-4441), error (in case) have been clearer in chef 11.4.4:

no such file or directory - file not found '/etc/chef/encrypted_data_bag_secret' 

i hope that's helpful.


Comments

Popular posts from this blog

Detect support for Shoutcast ICY MP3 without navigator.userAgent in Firefox? -

web - SVG not rendering properly in Firefox -

visual studio - TFS will not accept changes I've made to a Java project -