Merge "use variable fernet-key data bag"

This commit is contained in:
Jenkins 2017-09-22 21:15:12 +00:00 committed by Gerrit Code Review
commit a66540d815
2 changed files with 4 additions and 3 deletions

View File

@ -33,7 +33,8 @@ directory key_repository do
end
node['openstack']['identity']['fernet']['keys'].each do |key_index|
key = secret('keystone', "fernet_key#{key_index}")
key = secret(node['openstack']['secret']['secrets_data_bag'],
"fernet_key#{key_index}")
file File.join(key_repository, key_index.to_s) do
content key
owner node['openstack']['identity']['user']

View File

@ -65,10 +65,10 @@ shared_context 'identity_stubs' do
.with('user', 'admin')
.and_return('admin')
allow_any_instance_of(Chef::Recipe).to receive(:secret)
.with('keystone', 'fernet_key0')
.with('secrets', 'fernet_key0')
.and_return('thisisfernetkey0')
allow_any_instance_of(Chef::Recipe).to receive(:secret)
.with('keystone', 'fernet_key1')
.with('secrets', 'fernet_key1')
.and_return('thisisfernetkey1')
allow_any_instance_of(Chef::Recipe).to receive(:rabbit_transport_url)
.with('identity')