placement: change default vhost & port

8778 port was removed from devstack for Nova Placement testing,
it overlaps with OpenStack Senlin.
Instead, we should use /placement vhost.

Note: this change is not backward compatible on purpose, we introduced
the placement service during Ocata cycle.

Change-Id: I74662aa4d6b6179cb8ef759b7d5df82b609aa7cc
This commit is contained in:
Emilien Macchi
2016-12-23 10:40:46 -05:00
parent 58ff414a66
commit fb0327d101
5 changed files with 20 additions and 20 deletions

View File

@@ -21,15 +21,15 @@
#
# [*public_url*]
# (optional) The endpoint's public url.
# Defaults to 'http://127.0.0.1:8778'
# Defaults to 'http://127.0.0.1/placement'
#
# [*internal_url*]
# (optional) The endpoint's internal url.
# Defaults to 'http://127.0.0.1:8778'
# Defaults to 'http://127.0.0.1/placement'
#
# [*admin_url*]
# (optional) The endpoint's admin url.
# Defaults to 'http://127.0.0.1:8778'
# Defaults to 'http://127.0.0.1/placement'
#
# [*region*]
# (optional) The region in which to place the endpoints
@@ -63,9 +63,9 @@ class nova::keystone::auth_placement(
$region = 'RegionOne',
$tenant = 'services',
$email = 'placement@localhost',
$public_url = 'http://127.0.0.1:8778',
$internal_url = 'http://127.0.0.1:8778',
$admin_url = 'http://127.0.0.1:8778',
$public_url = 'http://127.0.0.1/placement',
$internal_url = 'http://127.0.0.1/placement',
$admin_url = 'http://127.0.0.1/placement',
$configure_endpoint = true,
$configure_user = true,
$configure_user_role = true,

View File

@@ -28,7 +28,7 @@
#
# [*api_port*]
# The port for Novai Placement API service.
# Optional. Defaults to 8778
# Optional. Defaults to 80
#
# [*bind_host*]
# The host/ip address Apache will listen on.
@@ -36,7 +36,7 @@
#
# [*path*]
# The prefix for the endpoint.
# Optional. Defaults to '/'
# Optional. Defaults to '/placement'
#
# [*ssl*]
# Use ssl ? (boolean)
@@ -84,9 +84,9 @@
#
class nova::wsgi::apache_placement (
$servername = $::fqdn,
$api_port = 8778,
$api_port = 80,
$bind_host = undef,
$path = '/',
$path = '/placement',
$ssl = true,
$workers = 1,
$ssl_cert = undef,

View File

@@ -124,7 +124,7 @@ describe 'basic nova' do
end
if os[:family].casecmp('RedHat') == 0
describe port(8778) do
describe port(80) do
it { is_expected.to be_listening }
end
end

View File

@@ -12,9 +12,9 @@ describe 'nova::keystone::auth_placement' do
:region => 'RegionOne',
:tenant => 'services',
:email => 'placement@localhost',
:public_url => 'http://127.0.0.1:8778',
:internal_url => 'http://127.0.0.1:8778',
:admin_url => 'http://127.0.0.1:8778' }
:public_url => 'http://127.0.0.1/placement',
:internal_url => 'http://127.0.0.1/placement',
:admin_url => 'http://127.0.0.1/placement' }
end
context 'with default parameters' do
@@ -36,9 +36,9 @@ describe 'nova::keystone::auth_placement' do
it { is_expected.to contain_keystone_endpoint('RegionOne/placement::placement').with(
:ensure => 'present',
:public_url => 'http://127.0.0.1:8778',
:admin_url => 'http://127.0.0.1:8778',
:internal_url => 'http://127.0.0.1:8778'
:public_url => 'http://127.0.0.1/placement',
:admin_url => 'http://127.0.0.1/placement',
:internal_url => 'http://127.0.0.1/placement'
)}
end

View File

@@ -65,7 +65,7 @@ describe 'nova::wsgi::apache_placement' do
it { is_expected.to contain_apache__vhost('placement_wsgi').with(
'servername' => 'some.host.tld',
'ip' => nil,
'port' => '8778',
'port' => '80',
'docroot' => "#{platform_params[:wsgi_script_path]}",
'docroot_owner' => 'nova',
'docroot_group' => 'nova',
@@ -79,7 +79,7 @@ describe 'nova::wsgi::apache_placement' do
'display-name' => 'placement_wsgi',
},
'wsgi_process_group' => 'placement-api',
'wsgi_script_aliases' => { '/' => "#{platform_params[:wsgi_script_path]}/nova-placement-api" },
'wsgi_script_aliases' => { '/placement' => "#{platform_params[:wsgi_script_path]}/nova-placement-api" },
'require' => 'File[placement_wsgi]'
)}
it { is_expected.to contain_concat("#{platform_params[:httpd_ports_file]}") }
@@ -136,7 +136,7 @@ describe 'nova::wsgi::apache_placement' do
'display-name' => 'placement-api',
},
'wsgi_process_group' => 'placement-api',
'wsgi_script_aliases' => { '/' => "#{platform_params[:wsgi_script_path]}/nova-placement-api" },
'wsgi_script_aliases' => { '/placement' => "#{platform_params[:wsgi_script_path]}/nova-placement-api" },
'require' => 'File[placement_wsgi]'
)}
end