Merge "Ssh: Replace hiera by lookup"

This commit is contained in:
Zuul 2022-05-04 01:54:46 +00:00 committed by Gerrit Code Review
commit 066649cdb4
1 changed files with 7 additions and 7 deletions

View File

@ -21,11 +21,11 @@
# #
# [*bannertext*] # [*bannertext*]
# The text used within /etc/issue and /etc/issue.net # The text used within /etc/issue and /etc/issue.net
# Defaults to hiera('BannerText') # Defaults to lookup('BannerText', undef, undef, undef)
# #
# [*motd*] # [*motd*]
# The text used within SSH Banner # The text used within SSH Banner
# Defaults to hiera('MOTD') # Defaults to lookup('MOTD', undef, undef, undef)
# #
# [*options*] # [*options*]
# Hash of SSHD options to set. See the puppet-ssh module documentation for # Hash of SSHD options to set. See the puppet-ssh module documentation for
@ -41,10 +41,10 @@
# Defaults to 'no' # Defaults to 'no'
class tripleo::profile::base::sshd ( class tripleo::profile::base::sshd (
$bannertext = hiera('BannerText', undef), $bannertext = lookup('BannerText', undef, undef, undef),
$motd = hiera('MOTD', undef), $motd = lookup('MOTD', undef, undef, undef),
$options = {}, $options = {},
$port = [22], $port = [22],
$password_authentication = 'no', $password_authentication = 'no',
) { ) {
@ -108,7 +108,7 @@ class tripleo::profile::base::sshd (
# NB (owalsh) in puppet-ssh hiera takes precedence over the class param # NB (owalsh) in puppet-ssh hiera takes precedence over the class param
# we need to control this, so error if it's set in hiera # we need to control this, so error if it's set in hiera
if hiera('ssh:server::options', undef) { if lookup('ssh:server::options', undef, undef, undef) {
err('ssh:server::options must not be set, use tripleo::profile::base::sshd::options') err('ssh:server::options must not be set, use tripleo::profile::base::sshd::options')
} }
class { 'ssh': class { 'ssh':