Add option to use hsm or not in connector class, SC-2670

This commit is contained in:
Patrik Holmqvist 2025-02-18 16:28:55 +01:00
parent 3c4ca71bf6
commit 27f52cdf38
Signed by: pahol
GPG key ID: 5D5B0D4E93F77273

View file

@ -5,6 +5,7 @@
# @param version Version of the docker image to use. (referenced in compose file)
# @param server_fqdn The FQDN of the server. (referenced in compose file)
# @param connector_directory The directory where all connector related config and files are stored. (referenced in compose file)
# @param use_hsm Configure if HSM is used or not
class eid::connector (
Enum['test', 'qa', 'prod'] $environment,
Enum['redis', 'memory'] $session_backend = 'redis',
@ -12,9 +13,12 @@ class eid::connector (
#String $connector_hostname = '',
String $server_fqdn = $facts['networking']['fqdn'],
String $connector_directory = '/opt/eidas-connector',
Boolean $use_hsm=true,
) {
$pkcs11_pin = safe_hiera('pkcs11_pin')
if $use_hsm {
$pkcs11_pin = safe_hiera('pkcs11_pin')
}
if $version and $pkcs11_pin != 'NOT_SET_IN_HIERA' {