@@ -304,6 +304,25 @@ impl<'a> RoleGroupBuilder<'a> {
304304 self . resource_names . role_group_config_map ( )
305305 } ;
306306
307+ let mut internal_tls_volume_service_scopes = vec ! [ ] ;
308+ if self
309+ . role_group_config
310+ . config
311+ . node_roles
312+ . contains ( & v1alpha1:: NodeRole :: ClusterManager )
313+ {
314+ internal_tls_volume_service_scopes
315+ . push ( self . node_config . seed_nodes_service_name . clone ( ) ) ;
316+ }
317+ let internal_tls_volume = self . build_tls_volume (
318+ & TLS_INTERNAL_VOLUME_NAME ,
319+ & self . cluster . tls_config . internal_secret_class ,
320+ internal_tls_volume_service_scopes,
321+ SecretFormat :: TlsPem ,
322+ & self . role_group_config . config . requested_secret_lifetime ,
323+ vec ! [ ROLE_GROUP_LISTENER_VOLUME_NAME . clone( ) ] ,
324+ ) ;
325+
307326 let mut volumes = vec ! [
308327 Volume {
309328 name: CONFIG_VOLUME_NAME . to_string( ) ,
@@ -333,27 +352,10 @@ impl<'a> RoleGroupBuilder<'a> {
333352 } ) ,
334353 ..Volume :: default ( )
335354 } ,
336- self . build_tls_volume(
337- & TLS_INTERNAL_VOLUME_NAME ,
338- & self . cluster. tls_config. internal_secret_class,
339- vec![ ] ,
340- SecretFormat :: TlsPem ,
341- & self . role_group_config. config. requested_secret_lifetime,
342- vec![ ROLE_GROUP_LISTENER_VOLUME_NAME . clone( ) ] ,
343- ) ,
355+ internal_tls_volume,
344356 ] ;
345357
346358 if let Some ( tls_http_secret_class_name) = & self . cluster . tls_config . server_secret_class {
347- let mut service_scopes = vec ! [ ] ;
348- if self
349- . role_group_config
350- . config
351- . node_roles
352- . contains ( & v1alpha1:: NodeRole :: ClusterManager )
353- {
354- service_scopes. push ( self . node_config . seed_nodes_service_name . clone ( ) ) ;
355- }
356-
357359 let mut listener_scopes = vec ! [ ROLE_GROUP_LISTENER_VOLUME_NAME . to_owned( ) ] ;
358360 if self . role_group_config . config . discovery_service_exposed {
359361 listener_scopes. push ( DISCOVERY_SERVICE_LISTENER_VOLUME_NAME . to_owned ( ) ) ;
@@ -362,7 +364,7 @@ impl<'a> RoleGroupBuilder<'a> {
362364 volumes. push ( self . build_tls_volume (
363365 & TLS_SERVER_VOLUME_NAME ,
364366 tls_http_secret_class_name,
365- service_scopes ,
367+ vec ! [ ] ,
366368 SecretFormat :: TlsPem ,
367369 & self . role_group_config . config . requested_secret_lifetime ,
368370 listener_scopes,
0 commit comments