Puppet Class: hdm
- Defined in:
- manifests/init.pp
Summary
HDM installation main classOverview
This class controls the installation of HDM
141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 |
# File 'manifests/init.pp', line 141
class hdm (
# installation parameter
String[1] $version = '3.0.0',
Enum['docker', 'rvm'] $method = 'docker',
String[1] $container_registry_url = 'ghcr.io/betadots/hdm',
Boolean $manage_docker = true,
String[1] $ruby_version = '3.3.1',
# required application parameter
Stdlib::Port $port = 3000,
Stdlib::IP::Address::Nosubnet $bind_ip = '0.0.0.0',
String[1] $hostname = $facts['networking']['fqdn'],
String[1] $timezone = $facts['timezone'],
Stdlib::Unixpath $hdm_path = '/etc/hdm',
String[1] $secret_key_base = '7a8509ab31fdb0c15c71c941d089474a',
String[1] $user = 'hdm',
String[1] $group = 'hdm',
String[1] $git_url = 'https://github.com/betadots/hdm.git',
Hdm::Puppetdb $puppetdb_settings = { 'server' => 'http://localhost:8080', },
Stdlib::Unixpath $puppet_code_dir = '/etc/puppetlabs/code',
Stdlib::Unixpath $puppet_dir = '/etc/puppetlabs',
String[1] $hdm_hiera_config_file = 'hiera.yaml',
# additional application parameter
Boolean $disable_authentication = false,
Boolean $allow_encryption = false,
Boolean $read_only = true,
Optional[Hdm::Gitdata] $git_data = undef,
Optional[Hdm::Ldap_settings] $ldap_settings = undef,
Optional[Sensitive[String[1]]] $ldap_bind_dn_password = undef,
Hash[String[1],Enum['yaml', 'eyaml']] $custom_lookup_function = {},
) {
if $ldap_settings {
if $ldap_bind_dn_password {
$final_ldap_settings = $ldap_settings + { bind_dn_password => $ldap_bind_dn_password }
} else {
$final_ldap_settings = $ldap_settings
}
} else {
$final_ldap_settings = {}
}
case $method {
'docker': {
$run_mode = 'production'
include hdm::docker
}
'rvm': {
$run_mode = 'development'
include hdm::rvm
}
default: {
fail('Unknown HDM installation method.')
}
}
}
|