3
0

OP#189 add the services

This commit is contained in:
2025-12-04 14:30:24 +01:00
parent 340306b15f
commit fd566a0af8
5 changed files with 8 additions and 3 deletions

View File

@@ -49,7 +49,6 @@ Configurable options:
See the full Puppet documentation including parameters in `docs/index.html`
# Wiki
[Pruning process](/wiki/pruning.md)
## Dependencies

View File

@@ -91,6 +91,12 @@ class prometheus_cd::main::files (
content => template('prometheus_cd/prometheus-prune-timer.erb'),
notify => Exec['systemd-daemon-reload'],
}
file { $ps_prune_log_file:
ensure => file,
owner => 'prometheus',
group => 'prometheus',
mode => '0644',
}
}
if $ps_enable_pruning == false {

View File

@@ -117,6 +117,7 @@ class prometheus_cd::params (
$ps_system_service_file = "${ps_system_file_dir}/override.conf"
$ps_pruning_svc_file = "${ps_system_dir}/prometheus-prune.service"
$ps_pruning_timer_file = "${ps_system_dir}/prometheus-prune.timer"
$ps_prune_log_file = '/var/log/prometheus-prune.log'
# services
$ps_prom_service = 'prometheus'

View File

@@ -4,7 +4,7 @@ set -euo pipefail
# Load environment
source <%= @ps_env_file %>
LOG_FILE="/var/log/prometheus-prune.log"
LOG_FILE="<%= @ps_prune_log_file %>"
echo "$(date '+%Y-%m-%d %H:%M:%S') Starting prune run" >> "$LOG_FILE"
# Find all TSDB blocks

View File

@@ -1 +0,0 @@
# The Pruning Process