Browse Source

Use SSL options from nova::

Currently they are set using nova_config in vncproxy.pp but now
they have been properly implemented in puppet-nova [1].

[1] https://review.openstack.org/#/c/582881/

Change-Id: Ifec1dd09eb9ae1acb80001cb0ede1c5efb118d17
Alfredo Moralejo 9 months ago
parent
commit
e93db2cc85

+ 14
- 0
packstack/puppet/modules/packstack/manifests/nova.pp View File

@@ -47,6 +47,16 @@ class packstack::nova ()
47 47
       $novahost = undef
48 48
     }
49 49
 
50
+    if hiera('CONFIG_HORIZON_SSL') == 'y' {
51
+      $ssl_only = true
52
+      $cert = hiera('CONFIG_VNC_SSL_CERT')
53
+      $key = hiera('CONFIG_VNC_SSL_KEY')
54
+    } else {
55
+      $ssl_only = false
56
+      $cert = undef
57
+      $key = undef
58
+    }
59
+
50 60
     class { '::nova':
51 61
       glance_api_servers            => "http://${nova_common_rabbitmq_cfg_storage_host}:9292",
52 62
       default_transport_url         => "rabbit://${rabbit_userid}:${rabbit_password}@${rabbit_host}:${rabbit_port}/",
@@ -65,5 +75,9 @@ class packstack::nova ()
65 75
       cpu_allocation_ratio          => hiera('CONFIG_NOVA_SCHED_CPU_ALLOC_RATIO'),
66 76
       ram_allocation_ratio          => hiera('CONFIG_NOVA_SCHED_RAM_ALLOC_RATIO'),
67 77
       host                          => $novahost,
78
+      ssl_only                      => $ssl_only,
79
+      cert                          => $cert,
80
+      key                           => $key,
68 81
     }
82
+
69 83
 }

+ 0
- 8
packstack/puppet/modules/packstack/manifests/nova/vncproxy.pp View File

@@ -1,13 +1,5 @@
1 1
 class packstack::nova::vncproxy ()
2 2
 {
3
-    if hiera('CONFIG_HORIZON_SSL') == 'y' {
4
-      nova_config {
5
-        'DEFAULT/ssl_only': value => true;
6
-        'DEFAULT/cert':     value => hiera('CONFIG_VNC_SSL_CERT');
7
-        'DEFAULT/key':      value => hiera('CONFIG_VNC_SSL_KEY');
8
-      }
9
-    }
10
-
11 3
     $vnc_bind_host = hiera('CONFIG_IP_VERSION') ? {
12 4
       'ipv6'  => '::0',
13 5
       default => '0.0.0.0',

Loading…
Cancel
Save