Run cinder-manage as correct user/group
We need to explicitly run cinder-manage with cinder user/group. Running as root may cause files in /var/log/cinder/* to be owned by root, and this will cause cinder services from being able to start (due to being unable to write to files in that directory). This is a non-issue when you install from packages as the package post-install typically does a cinder-manage with the correct user, and this ensures logs are created w/ correct ownership. Change-Id: I50c94646a993ae5eb2e8775d979a4c0a73f2f4f2
This commit is contained in:
parent
85a7d6efd5
commit
aa8d617808
|
@ -62,7 +62,10 @@ service_pass = get_password 'service', 'openstack-block-storage'
|
|||
|
||||
auth_uri = auth_uri_transform(identity_endpoint.to_s, node['openstack']['block-storage']['api']['auth']['version'])
|
||||
|
||||
execute 'cinder-manage db sync'
|
||||
execute 'cinder-manage db sync' do
|
||||
user node['openstack']['block-storage']['user']
|
||||
group node['openstack']['block-storage']['group']
|
||||
end
|
||||
|
||||
template '/etc/cinder/api-paste.ini' do
|
||||
source 'api-paste.ini.erb'
|
||||
|
|
|
@ -49,7 +49,7 @@ describe 'openstack-block-storage::api' do
|
|||
end
|
||||
|
||||
it 'runs db migrations' do
|
||||
expect(chef_run).to run_execute('cinder-manage db sync')
|
||||
expect(chef_run).to run_execute('cinder-manage db sync').with(user: 'cinder', group: 'cinder')
|
||||
end
|
||||
|
||||
describe 'api-paste.ini' do
|
||||
|
|
Loading…
Reference in New Issue