allow specifying bind port

Much like a previous commit to allow specifying a bind IP for the API
service (3a576ac), this commit adds a similar ability to specify a bind port.

Change-Id: I62caf397995fbcf3a202992b353c05cc027d07b6
This commit is contained in:
Darren Birkett 2014-04-14 11:07:20 +01:00
parent 5cdb6ba827
commit 1fdbba053a
3 changed files with 9 additions and 4 deletions

View File

@ -72,7 +72,8 @@ template '/etc/cinder/cinder.conf' do
glance_host: glance_api_endpoint.host,
glance_port: glance_api_endpoint.port,
solidfire_pass: solidfire_pass,
volume_api_address: cinder_api_endpoint.host
volume_api_bind_address: cinder_api_endpoint.host,
volume_api_bind_port: cinder_api_endpoint.port
)
end

View File

@ -68,6 +68,11 @@ describe 'openstack-block-storage::cinder-common' do
expect(chef_run).to render_file(file.name).with_content('osapi_volume_listen=1.1.1.1')
end
it 'has osapi_volume_listen_port set' do
node.set['openstack']['endpoints']['block-storage-api']['port'] = '9999'
expect(chef_run).to render_file(file.name).with_content('osapi_volume_listen_port=9999')
end
it 'has rpc_thread_pool_size' do
expect(chef_run).to render_file(file.name).with_content('rpc_thread_pool_size=64')
end

View File

@ -215,12 +215,11 @@ quota_driver=<%= node["openstack"]["block-storage"]["quota_driver"] %>
#### periodic task scheduler to reduce stampeding. (Disable by
#### setting to 0)
osapi_volume_listen=<%= @volume_api_address %>
osapi_volume_listen=<%= @volume_api_bind_address %>
#### (StrOpt) IP address for OpenStack Volume API to listen
# osapi_volume_listen_port=8776
#### (IntOpt) port for os volume api to listen
osapi_volume_listen_port=<%= @volume_api_bind_port %>
######## defined in cinder.test ########