Drop redundant default for server_proxyclient_address options

These options default to 127.0.0.1, so we don't have to define
explicit defaults in the module.

Change-Id: Ic6074a8f652b71046a3dfc636e0b5c795cb7858c
This commit is contained in:
Takashi Kajinami
2025-01-03 11:10:01 +09:00
parent 4044c4d598
commit 7104f1f818
4 changed files with 6 additions and 6 deletions

View File

@@ -268,7 +268,7 @@ class nova::compute (
$ensure_package = 'present',
Boolean $vnc_enabled = true,
Boolean $spice_enabled = false,
$vncserver_proxyclient_address = '127.0.0.1',
$vncserver_proxyclient_address = $facts['os_service_default'],
$vncproxy_host = undef,
$vncproxy_protocol = 'http',
$vncproxy_port = '6080',

View File

@@ -15,7 +15,7 @@
# [*server_proxyclient_address*]
# (optional) Management IP Address on which instance spiceservers will
# listen on the compute host.
# Defaults to '127.0.0.1'
# Defaults to $facts['os_service_default']
#
# [*proxy_host*]
# (optional) Host for the html5 console proxy
@@ -36,7 +36,7 @@
class nova::compute::spice(
Boolean $agent_enabled = true,
$server_listen = $facts['os_service_default'],
$server_proxyclient_address = '127.0.0.1',
$server_proxyclient_address = $facts['os_service_default'],
$proxy_host = undef,
$proxy_protocol = 'http',
$proxy_port = '6082',

View File

@@ -27,7 +27,7 @@ describe 'nova::compute' do
it 'does not configure vncproxy base url in nova.conf' do
is_expected.to contain_nova_config('vnc/enabled').with_value(true)
is_expected.to_not contain_nova_config('vnc/novncproxy_base_url')
is_expected.to contain_nova_config('vnc/server_proxyclient_address').with_value('127.0.0.1')
is_expected.to contain_nova_config('vnc/server_proxyclient_address').with_value('<SERVICE DEFAULT>')
end
it 'should have spice disabled' do
@@ -136,7 +136,7 @@ describe 'nova::compute' do
it 'configures vnc in nova.conf' do
is_expected.to contain_nova_config('vnc/enabled').with_value(true)
is_expected.to contain_nova_config('vnc/server_proxyclient_address').with_value('127.0.0.1')
is_expected.to contain_nova_config('vnc/server_proxyclient_address').with_value('<SERVICE DEFAULT>')
is_expected.to contain_nova_config('vnc/novncproxy_base_url').with_value(
'http://127.0.0.1:6080/vnc_auto.html'
)

View File

@@ -3,7 +3,7 @@ require 'spec_helper'
describe 'nova::compute::spice' do
shared_examples 'nova::compute::spice' do
it { should contain_nova_config('spice/agent_enabled').with_value('true')}
it { should contain_nova_config('spice/server_proxyclient_address').with_value('127.0.0.1')}
it { should contain_nova_config('spice/server_proxyclient_address').with_value('<SERVICE DEFAULT>')}
it { should contain_nova_config('spice/html5proxy_base_url').with_value('<SERVICE DEFAULT>')}
it { should contain_nova_config('spice/server_listen').with_value('<SERVICE DEFAULT>')}