From 1623a2bc72f041e56dd3931377ef1d6e30de6e0e Mon Sep 17 00:00:00 2001 From: Iago Estrela Date: Wed, 12 Jan 2022 13:54:38 -0300 Subject: [PATCH] Rename VNC deprecated opts vncserver_listen and vncserver_proxyclient_address were deprecated, this change aims to replace them with the versioned name. Test plan: PASS: Verify that vncserver_listen was changed to server_listen inside nova openstack manifest (system helm-override-show). Story: 2009783 Task: 44273 Signed-off-by: Iago Estrela Change-Id: I7bc9087bce8926595fd1f0dbc82d722fd26b45a0 --- openstack-helm/centos/openstack-helm.spec | 2 + ...e-deprecated-Nova-VNC-configurations.patch | 70 +++++++++++++++++++ .../debian/deb_folder/patches/series | 1 + ...e-deprecated-Nova-VNC-configurations.patch | 70 +++++++++++++++++++ .../k8sapp_openstack/helm/nova.py | 6 +- .../manifests/manifest.yaml | 2 +- 6 files changed, 147 insertions(+), 4 deletions(-) create mode 100644 openstack-helm/debian/deb_folder/patches/0012-Replace-deprecated-Nova-VNC-configurations.patch create mode 100644 openstack-helm/files/0012-Replace-deprecated-Nova-VNC-configurations.patch diff --git a/openstack-helm/centos/openstack-helm.spec b/openstack-helm/centos/openstack-helm.spec index d7fb66cf..3a4de558 100644 --- a/openstack-helm/centos/openstack-helm.spec +++ b/openstack-helm/centos/openstack-helm.spec @@ -30,6 +30,7 @@ Patch08: 0008-Disabling-helm3_hook.patch Patch09: 0009-Add-flavor-extra-spec-hw-pci_irq_affinity_mask.patch Patch10: 0010-Enable-taint-toleration-for-Openstack-services.patch Patch11: 0011-Fix-nova-compute-ssh-init-to-execute-as-runAsUser.patch +Patch12: 0012-Replace-deprecated-Nova-VNC-configurations.patch BuildRequires: helm BuildRequires: openstack-helm-infra @@ -52,6 +53,7 @@ Openstack Helm charts %patch09 -p1 %patch10 -p1 %patch11 -p1 +%patch12 -p1 %build # Stage helm-toolkit in the local repo diff --git a/openstack-helm/debian/deb_folder/patches/0012-Replace-deprecated-Nova-VNC-configurations.patch b/openstack-helm/debian/deb_folder/patches/0012-Replace-deprecated-Nova-VNC-configurations.patch new file mode 100644 index 00000000..878c0a1a --- /dev/null +++ b/openstack-helm/debian/deb_folder/patches/0012-Replace-deprecated-Nova-VNC-configurations.patch @@ -0,0 +1,70 @@ +From 1cf04aef5dcfec540b71f5ccb2b9702d81ca0184 Mon Sep 17 00:00:00 2001 +From: Iago Estrela +Date: Wed, 12 Jan 2022 17:46:10 -0300 +Subject: [PATCH] Replace deprecated Nova VNC configurations + +Replace deprecated opts of Nova VNC Server configurations. + +Signed-off-by: Iago Estrela +Change-Id: I7103d2ae77bec442790a0bbed3aac53fe1e7641e +--- + nova/templates/bin/_nova-console-compute-init.sh.tpl | 2 +- + nova/templates/bin/_nova-console-proxy-init.sh.tpl | 8 ++++---- + nova/values.yaml | 2 +- + 3 files changed, 6 insertions(+), 6 deletions(-) + +diff --git a/nova/templates/bin/_nova-console-compute-init.sh.tpl b/nova/templates/bin/_nova-console-compute-init.sh.tpl +index 6718fabb..cb333305 100644 +--- a/nova/templates/bin/_nova-console-compute-init.sh.tpl ++++ b/nova/templates/bin/_nova-console-compute-init.sh.tpl +@@ -53,7 +53,7 @@ if [ "${console_kind}" == "novnc" ] ; then + cat > /tmp/pod-shared/nova-console.conf < /tmp/pod-shared/nova-console.conf </tmp/pod-shared/nova-vnc.ini + [vnc] +-vncserver_proxyclient_address = $client_address +-vncserver_listen = $listen_ip ++server_proxyclient_address = $client_address ++server_listen = $listen_ip + EOF + elif [ "${console_kind}" == "spice" ] ; then + cat </tmp/pod-shared/nova-spice.ini +diff --git a/nova/values.yaml b/nova/values.yaml +index cdb14575..f663c805 100644 +--- a/nova/values.yaml ++++ b/nova/values.yaml +@@ -1446,7 +1446,7 @@ conf: + resume_guests_state_on_host_boot: True + vnc: + novncproxy_host: 0.0.0.0 +- vncserver_listen: 0.0.0.0 ++ server_listen: 0.0.0.0 + # This would be set by each compute nodes's ip + # server_proxyclient_address: 127.0.0.1 + spice: +-- +2.17.1 diff --git a/openstack-helm/debian/deb_folder/patches/series b/openstack-helm/debian/deb_folder/patches/series index 94be8036..a0515401 100644 --- a/openstack-helm/debian/deb_folder/patches/series +++ b/openstack-helm/debian/deb_folder/patches/series @@ -9,3 +9,4 @@ 0009-Add-flavor-extra-spec-hw-pci_irq_affinity_mask.patch 0010-Enable-taint-toleration-for-Openstack-services.patch 0011-Fix-nova-compute-ssh-init-to-execute-as-runAsUser.patch +0012-Replace-deprecated-Nova-VNC-configurations.patch \ No newline at end of file diff --git a/openstack-helm/files/0012-Replace-deprecated-Nova-VNC-configurations.patch b/openstack-helm/files/0012-Replace-deprecated-Nova-VNC-configurations.patch new file mode 100644 index 00000000..878c0a1a --- /dev/null +++ b/openstack-helm/files/0012-Replace-deprecated-Nova-VNC-configurations.patch @@ -0,0 +1,70 @@ +From 1cf04aef5dcfec540b71f5ccb2b9702d81ca0184 Mon Sep 17 00:00:00 2001 +From: Iago Estrela +Date: Wed, 12 Jan 2022 17:46:10 -0300 +Subject: [PATCH] Replace deprecated Nova VNC configurations + +Replace deprecated opts of Nova VNC Server configurations. + +Signed-off-by: Iago Estrela +Change-Id: I7103d2ae77bec442790a0bbed3aac53fe1e7641e +--- + nova/templates/bin/_nova-console-compute-init.sh.tpl | 2 +- + nova/templates/bin/_nova-console-proxy-init.sh.tpl | 8 ++++---- + nova/values.yaml | 2 +- + 3 files changed, 6 insertions(+), 6 deletions(-) + +diff --git a/nova/templates/bin/_nova-console-compute-init.sh.tpl b/nova/templates/bin/_nova-console-compute-init.sh.tpl +index 6718fabb..cb333305 100644 +--- a/nova/templates/bin/_nova-console-compute-init.sh.tpl ++++ b/nova/templates/bin/_nova-console-compute-init.sh.tpl +@@ -53,7 +53,7 @@ if [ "${console_kind}" == "novnc" ] ; then + cat > /tmp/pod-shared/nova-console.conf < /tmp/pod-shared/nova-console.conf </tmp/pod-shared/nova-vnc.ini + [vnc] +-vncserver_proxyclient_address = $client_address +-vncserver_listen = $listen_ip ++server_proxyclient_address = $client_address ++server_listen = $listen_ip + EOF + elif [ "${console_kind}" == "spice" ] ; then + cat </tmp/pod-shared/nova-spice.ini +diff --git a/nova/values.yaml b/nova/values.yaml +index cdb14575..f663c805 100644 +--- a/nova/values.yaml ++++ b/nova/values.yaml +@@ -1446,7 +1446,7 @@ conf: + resume_guests_state_on_host_boot: True + vnc: + novncproxy_host: 0.0.0.0 +- vncserver_listen: 0.0.0.0 ++ server_listen: 0.0.0.0 + # This would be set by each compute nodes's ip + # server_proxyclient_address: 127.0.0.1 + spice: +-- +2.17.1 diff --git a/python-k8sapp-openstack/k8sapp_openstack/k8sapp_openstack/helm/nova.py b/python-k8sapp-openstack/k8sapp_openstack/k8sapp_openstack/helm/nova.py index 581bacde..3ff7347c 100644 --- a/python-k8sapp-openstack/k8sapp_openstack/k8sapp_openstack/helm/nova.py +++ b/python-k8sapp-openstack/k8sapp_openstack/k8sapp_openstack/helm/nova.py @@ -507,12 +507,12 @@ class NovaHelm(openstack.OpenstackBaseHelm): default_config.update({'my_ip': cluster_host_ip}) if ip_family == 4: - vnc_config.update({'vncserver_listen': '0.0.0.0'}) + vnc_config.update({'server_listen': '0.0.0.0'}) elif ip_family == 6: - vnc_config.update({'vncserver_listen': '::0'}) + vnc_config.update({'server_listen': '::0'}) libvirt_config.update({'live_migration_inbound_addr': cluster_host_ip}) - vnc_config.update({'vncserver_proxyclient_address': cluster_host_ip}) + vnc_config.update({'server_proxyclient_address': cluster_host_ip}) def _get_ssh_subnet(self): address_pool = self.dbapi.address_pool_get(self.cluster_host_network.pool_uuid) diff --git a/stx-openstack-helm/stx-openstack-helm/manifests/manifest.yaml b/stx-openstack-helm/stx-openstack-helm/manifests/manifest.yaml index 257ee1ce..11239ae1 100644 --- a/stx-openstack-helm/stx-openstack-helm/manifests/manifest.yaml +++ b/stx-openstack-helm/stx-openstack-helm/manifests/manifest.yaml @@ -1275,7 +1275,7 @@ data: auth_url: http://keystone.openstack.svc.cluster.local:80/v3 vnc: novncproxy_host: "::" - vncserver_listen: "::" + server_listen: "::" spice: html5proxy_host: "::" server_listen: "::"