Allow binding locally to different IP than endpoint IP

Sometimes you want the actual endpoint IP to be a load
balanced IP, but the bind IP to be a local IP (different per node).

This change allows that by using attributes from the [orchestration-*-bind]
namespace

Implements blueprint increase-ip-binding-flexibility

Change-Id: I9ea0e1e61c23026bf24926b264e289ff80314ac2
This commit is contained in:
Darren Birkett 2014-04-25 12:41:12 +01:00
parent ea9b5d3632
commit 2863e67667
3 changed files with 28 additions and 12 deletions

View File

@ -110,6 +110,22 @@ TODO: move rabbit parameters under openstack["orchestration"]["mq"]
* `openstack["orchestration"]["mq"]["qpid"]["protocol"]` - Protocol to use. Default tcp.
* `openstack["orchestration"]["mq"]["qpid"]["tcp_nodelay"]` - Disable the Nagle algorithm. default disabled.
The following attributes are defined in attributes/default.rb of the common cookbook, but are documented here due to their relevance:
* `openstack['endpoints']['orchestration-api-bind']['host']` - The IP address to bind the service to
* `openstack['endpoints']['orchestration-api-bind']['port']` - The port to bind the service to
* `openstack['endpoints']['orchestration-api-bind']['bind_interface']` - The interface name to bind the service to
* `openstack['endpoints']['orchestration-api-cfn-bind']['host']` - The IP address to bind the service to
* `openstack['endpoints']['orchestration-api-cfn-bind']['port']` - The port to bind the service to
* `openstack['endpoints']['orchestration-api-cfn-bind']['bind_interface']` - The interface name to bind the-cfn service to
* `openstack['endpoints']['orchestration-api-cloudwatch-bind']['host']` - The IP address to bind the service to
* `openstack['endpoints']['orchestration-api-cloudwatch-bind']['port']` - The port to bind the service to
* `openstack['endpoints']['orchestration-api-cloudwatch-bind']['bind_interface']` - The interface name to bind the-cloudwatch service to
If the value of the 'bind_interface' attribute is non-nil, then the service will be bound to the first IP address on that interface. If the value of the 'bind_interface' attribute is nil, then the service will be bound to the IP address specifie>
Testing
=====

View File

@ -53,9 +53,9 @@ sql_connection = db_uri('orchestration', db_user, db_pass)
identity_endpoint = endpoint 'identity-api'
identity_admin_endpoint = endpoint 'identity-admin'
heat_api_endpoint = endpoint 'orchestration-api'
heat_api_cfn_endpoint = endpoint 'orchestration-api-cfn'
heat_api_cloudwatch_endpoint = endpoint 'orchestration-api-cloudwatch'
heat_api_bind = endpoint 'orchestration-api-bind'
heat_api_cfn_bind = endpoint 'orchestration-api-cfn-bind'
heat_api_cloudwatch_bind = endpoint 'orchestration-api-cloudwatch-bind'
service_pass = get_password 'service', 'openstack-orchestration'
@ -105,9 +105,9 @@ template '/etc/heat/heat.conf' do
identity_admin_endpoint: identity_admin_endpoint,
service_pass: service_pass,
sql_connection: sql_connection,
heat_api_endpoint: heat_api_endpoint,
heat_api_cfn_endpoint: heat_api_cfn_endpoint,
heat_api_cloudwatch_endpoint: heat_api_cloudwatch_endpoint
heat_api_bind: heat_api_bind,
heat_api_cfn_bind: heat_api_cfn_bind,
heat_api_cloudwatch_bind: heat_api_cloudwatch_bind
)
end

View File

@ -921,10 +921,10 @@ qpid_reconnect_interval=<%= node["openstack"]["mq"]["orchestration"]["qpid"]["re
# Address to bind the server. Useful when selecting a
# particular network interface. (string value)
bind_host=<%= @heat_api_endpoint.host %>
bind_host=<%= @heat_api_bind.host %>
# The port on which the server will listen. (integer value)
bind_port=<%= @heat_api_endpoint.port %>
bind_port=<%= @heat_api_bind.port %>
# Number of backlog requests to configure the socket with.
# (integer value)
@ -956,10 +956,10 @@ bind_port=<%= @heat_api_endpoint.port %>
# Address to bind the server. Useful when selecting a
# particular network interface. (string value)
bind_host=<%= @heat_api_cfn_endpoint.host %>
bind_host=<%= @heat_api_cfn_bind.host %>
# The port on which the server will listen. (integer value)
bind_port=<%= @heat_api_cfn_endpoint.port %>
bind_port=<%= @heat_api_cfn_bind.port %>
# Number of backlog requests to configure the socket with.
# (integer value)
@ -991,10 +991,10 @@ bind_port=<%= @heat_api_cfn_endpoint.port %>
# Address to bind the server. Useful when selecting a
# particular network interface. (string value)
bind_host=<%= @heat_api_cloudwatch_endpoint.host %>
bind_host=<%= @heat_api_cloudwatch_bind.host %>
# The port on which the server will listen. (integer value)
bind_port=<%= @heat_api_cloudwatch_endpoint.port %>
bind_port=<%= @heat_api_cloudwatch_bind.port %>
# Number of backlog requests to configure the socket with.
# (integer value)