diff --git a/manifests/compute/libvirt.pp b/manifests/compute/libvirt.pp index 352a51322..b323ef785 100644 --- a/manifests/compute/libvirt.pp +++ b/manifests/compute/libvirt.pp @@ -154,11 +154,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 } if $::osfamily == 'RedHat' { 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 1ebe9f495..e855be874 100644 --- a/spec/classes/nova_compute_libvirt_spec.rb +++ b/spec/classes/nova_compute_libvirt_spec.rb @@ -145,16 +145,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', @@ -290,15 +280,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 'with default parameters on Fedora' do