compute: Change Spice for VNC

Signed-off-by: Emilien Macchi <emilien.macchi@enovance.com>
This commit is contained in:
Emilien Macchi 2014-01-05 11:42:21 +01:00
parent 57bb8b9b12
commit 061f9799ec
4 changed files with 27 additions and 36 deletions

View File

@ -30,7 +30,8 @@ class privatecloud::compute::controller(
'nova::cert',
'nova::consoleauth',
'nova::conductor',
'nova::spicehtml5proxy',
# TODO(Emilien) Migrate to spice asap
'nova::vncproxy',
]:
enabled => true,
}

View File

@ -17,10 +17,13 @@
#
class privatecloud::compute::hypervisor(
$api_eth = $os_params::api_eth,
$libvirt_type = $os_params::libvirt_type,
$api_eth = $os_params::api_eth,
$libvirt_type = $os_params::libvirt_type,
$ks_nova_internal_proto = $os_params::ks_nova_internal_proto,
$ks_nova_internal_host = $os_params::ks_nova_internal_host
$ks_nova_internal_host = $os_params::ks_nova_internal_host,
$ks_nova_public_host = $os_params::ks_nova_public_host,
$nova_ssh_private_key = $os_params::nova_ssh_private_key,
$nova_ssh_public_key = $os_params::nova_ssh_public_key
) {
include 'privatecloud::compute'
@ -46,14 +49,14 @@ class privatecloud::compute::hypervisor(
mode => '0600',
owner => 'nova',
group => 'nova',
content => $os_params::nova_ssh_private_key
content => $nova_ssh_private_key
} ->
file{ '/var/lib/nova/.ssh/authorized_keys':
ensure => present,
mode => '0600',
owner => 'nova',
group => 'nova',
content => $os_params::nova_ssh_public_key
content => $nova_ssh_public_key
} ->
file{ '/var/lib/nova/.ssh/config':
ensure => present,
@ -67,11 +70,12 @@ Host *
}
class { 'nova::compute':
enabled => true,
vnc_enabled => false,
#TODO(EmilienM) Bug #1259545 currently WIP
virtio_nic => false,
neutron_enabled => true
enabled => true,
vncproxy_host => $ks_nova_public_host,
vncserver_proxyclient_address => $api_eth,
#TODO(EmilienM) Bug #1259545 currently WIP:
virtio_nic => false,
neutron_enabled => true
}
class { 'nova::compute::libvirt':
@ -88,14 +92,6 @@ Host *
refreshonly => true
}
class { 'nova::compute::spice':
agent_enabled => true,
server_listen => '0.0.0.0',
server_proxyclient_address => $api_eth,
proxy_protocol => $ks_nova_internal_proto,
proxy_host => $ks_nova_internal_host,
}
class { 'nova::compute::neutron': }
}

View File

@ -72,8 +72,8 @@ describe 'privatecloud::compute::controller' do
should contain_class('nova::conductor').with(:enabled => true)
end
it 'configure nova-spircehtml5proxy' do
should contain_class('nova::spicehtml5proxy').with(:enabled => true)
it 'configure nova-vncproxy' do
should contain_class('nova::vncproxy').with(:enabled => true)
end
it 'configure nova-api' do
@ -101,7 +101,7 @@ describe 'privatecloud::compute::controller' do
end
#TODO(Emilien) Problem with Spice: http://paste.openstack.org/show/pxIyzg5gqeJVR2nUPtoB/
# it_configures 'openstack compute controller'
it_configures 'openstack compute controller'
end
end

View File

@ -38,7 +38,10 @@ describe 'privatecloud::compute::hypervisor' do
let :params do
{ :libvirt_type => 'kvm',
:api_eth => '10.0.0.1',
:nova_ssh_private_key => 'secrete',
:nova_ssh_public_key => 'public',
:ks_nova_internal_proto => 'http',
:ks_nova_public_host => '7.7.7.7',
:ks_nova_internal_host => '10.0.0.1' }
end
@ -58,10 +61,11 @@ describe 'privatecloud::compute::hypervisor' do
it 'configure nova-compute' do
should contain_class('nova::compute').with(
:enabled => true,
:vnc_enabled => false,
:virtio_nic => false,
:neutron_enabled => true
:enabled => true,
:vncproxy_host => '7.7.7.7',
:vncserver_proxyclient_address => '10.0.0.1',
:virtio_nic => false,
:neutron_enabled => true
)
end
@ -73,16 +77,6 @@ describe 'privatecloud::compute::hypervisor' do
)
end
it 'configure nova spice agent' do
should contain_class('nova::compute::spice').with(
:agent_enabled => true,
:server_listen => '0.0.0.0',
:server_proxyclient_address => '10.0.0.1',
:proxy_protocol => 'http',
:proxy_host => '10.0.0.1'
)
end
it 'configure nova compute with neutron' do
should contain_class('nova::compute::neutron')
end