diff --git a/manifests/compute/libvirt.pp b/manifests/compute/libvirt.pp index f8f653650..c5965e9eb 100644 --- a/manifests/compute/libvirt.pp +++ b/manifests/compute/libvirt.pp @@ -171,11 +171,7 @@ class nova::compute::libvirt ( } if $migration_support { - if $vncserver_listen != '0.0.0.0' and $vncserver_listen != '::0' { - fail('For migration support to work, you MUST set vncserver_listen to \'0.0.0.0\' or \'::0\'') - } else { - include ::nova::migration::libvirt - } + include ::nova::migration::libvirt } # manage_libvirt_services is here for backward compatibility to support diff --git a/releasenotes/notes/fix_vncserver_listen-e48f7c8b9cda25e4.yaml b/releasenotes/notes/fix_vncserver_listen-e48f7c8b9cda25e4.yaml new file mode 100644 index 000000000..3d1d7b0d8 --- /dev/null +++ b/releasenotes/notes/fix_vncserver_listen-e48f7c8b9cda25e4.yaml @@ -0,0 +1,6 @@ +--- +fixes: + - Fixes `bug 1660099 + `__ so we don't restrict + vncserver_listen to be binded on 0.0.0.0, which has been wrong for long time. + Nova allows to bind on any IP and live migration will be supported. diff --git a/spec/classes/nova_compute_libvirt_spec.rb b/spec/classes/nova_compute_libvirt_spec.rb index 6a8ceaa4b..d501291ae 100644 --- a/spec/classes/nova_compute_libvirt_spec.rb +++ b/spec/classes/nova_compute_libvirt_spec.rb @@ -170,16 +170,6 @@ describe 'nova::compute::libvirt' do it { is_expected.to contain_file_line('/etc/libvirt/libvirtd.conf auth_tcp').with(:line => "auth_tcp = \"none\"") } end - context 'with vncserver_listen not set to 0.0.0.0' do - let :params do - { :vncserver_listen => '127.0.0.1', - :migration_support => true } - end - - it { expect { is_expected.to contain_class('nova::compute::libvirt') }.to \ - raise_error(Puppet::Error, /For migration support to work, you MUST set vncserver_listen to '0.0.0.0' or '::0'/) } - end - context 'with custom libvirt service name on Debian platforms' do let :params do { :libvirt_service_name => 'libvirtd', @@ -322,15 +312,6 @@ describe 'nova::compute::libvirt' do it { is_expected.to contain_file_line('/etc/libvirt/libvirtd.conf auth_tcp').with(:line => "auth_tcp = \"none\"") } end - context 'with vncserver_listen not set to 0.0.0.0' do - let :params do - { :vncserver_listen => '127.0.0.1', - :migration_support => true } - end - - it { expect { is_expected.to contain_class('nova::compute::libvirt') }.to \ - raise_error(Puppet::Error, /For migration support to work, you MUST set vncserver_listen to '0.0.0.0'/) } - end end describe 'when manage_libvirt_services is set to false' do