Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added configuration to enable/disable maintenance with Puppet #170

Merged
merged 3 commits into from
Jan 21, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions manifests/config.pp
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,19 @@
mode => '0755',
}

if $openondemand::maintenance_enabled {
$maintenance_enable_ensure = 'file'
} else {
$maintenance_enable_ensure = 'absent'
}

file { '/etc/ood/maintenance.enable':
ensure => $maintenance_enable_ensure,
owner => 'root',
group => 'root',
mode => '0644',
}

file { '/etc/ood/config':
ensure => 'directory',
owner => 'root',
Expand Down
3 changes: 3 additions & 0 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,8 @@
# Source for maintenance index.html
# @param maintenance_content
# Content for maintenance index.html
# @param maintenance_enabled
# Enable maintenance mode in OOD
# @param security_csp_frame_ancestors
# ood_portal.yml security_csp_frame_ancestors
# @param security_strict_transport
Expand Down Expand Up @@ -286,6 +288,7 @@
Array $maintenance_ip_allowlist = [],
Optional[String] $maintenance_source = undef,
Optional[String] $maintenance_content = undef,
Optional[Boolean] $maintenance_enabled = undef,
Optional[Variant[String, Boolean]] $security_csp_frame_ancestors = undef,
Boolean $security_strict_transport = true,
String $lua_root = '/opt/ood/mod_ood_proxy/lib',
Expand Down
Loading