File tree Expand file tree Collapse file tree 2 files changed +20
-4
lines changed Expand file tree Collapse file tree 2 files changed +20
-4
lines changed Original file line number Diff line number Diff line change 3636# @param strip_128_bit_ciphers
3737# **DEPRECATED** - EL6-only - Will be removed in a future release
3838#
39+ # @param client_tls
40+ # Set to false to disable setting up client-side TLS
41+ #
3942# @param debug_level
4043# @param debug_timestamps
4144# @param debug_microseconds
341344 Optional[Integer[0]] $ldap_idmap_range_size = undef ,
342345 Optional[String[1]] $ldap_idmap_default_domain_sid = undef ,
343346 Optional[String[1]] $ldap_idmap_default_domain = undef ,
344- Boolean $ldap_idmap_autorid_compat = false
347+ Boolean $ldap_idmap_autorid_compat = false ,
348+ Boolean $client_tls = true ,
345349) {
346350 include $module_name
347351
354358
355359 if $app_pki_ca_dir {
356360 $ldap_tls_cacertdir = $app_pki_ca_dir
357- } else {
361+ } elsif $client_tls {
358362 $ldap_tls_cacertdir = " ${sssd::app_pki_dir} /cacerts"
359363 }
360364
361365 if $app_pki_key {
362366 $ldap_tls_key = $app_pki_key
363- } else {
367+ } elsif $client_tls {
364368 $ldap_tls_key = " ${sssd::app_pki_dir} /private/${$facts ['networking']['fqdn']}.pem"
365369 }
366370
367371 if $app_pki_cert {
368372 $ldap_tls_cert = $app_pki_cert
369- } else {
373+ } elsif $client_tls {
370374 $ldap_tls_cert = " ${sssd::app_pki_dir} /public/${$facts ['networking']['fqdn']}.pub"
371375 }
372376
Original file line number Diff line number Diff line change 167167 }
168168 end
169169
170+ context 'with client_tls set to false' do
171+ let ( :params ) { { :client_tls => false } }
172+
173+ it { is_expected . to compile . with_all_deps }
174+ it {
175+ is_expected . to create_sssd__config__entry ( "puppet_provider_#{ title } _ldap" )
176+ . without_content ( %r(ldap_tls_cacertdir) )
177+ . without_content ( %r(ldap_tls_key) )
178+ . without_content ( %r(ldap_tls_cert) )
179+ }
180+ end
181+
170182 # This set of parameters exercises the logic in the code but is NOT at all
171183 # realistic!
172184 context 'with other optional parameters set' do
You can’t perform that action at this time.
0 commit comments