diff --git a/doc/file.README.html b/doc/file.README.html index 19eb6cd..b3a1a3f 100644 --- a/doc/file.README.html +++ b/doc/file.README.html @@ -87,8 +87,6 @@ diff --git a/doc/index.html b/doc/index.html index 8f24fbf..ea25804 100644 --- a/doc/index.html +++ b/doc/index.html @@ -87,8 +87,6 @@ diff --git a/doc/puppet_classes/prometheus_cd_3A_3Amain_3A_3Adirs.html b/doc/puppet_classes/prometheus_cd_3A_3Amain_3A_3Adirs.html index 540bff1..789e8a6 100644 --- a/doc/puppet_classes/prometheus_cd_3A_3Amain_3A_3Adirs.html +++ b/doc/puppet_classes/prometheus_cd_3A_3Amain_3A_3Adirs.html @@ -117,7 +117,18 @@ 19 20 21 -22 +22 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33
# File 'manifests/main/dirs.pp', line 6
@@ -126,7 +137,7 @@ class prometheus_cd::main::dirs (
 ) inherits prometheus_cd::params {
   require prometheus_cd::main::install
   if ($ps_prom_host == $fqdn) and ($manage_prometheus == true)  {
-    # prometheus directors
+    # prometheus directory
     file { $ps_main_dir:
       ensure   => directory,
       owner    => 'root',
@@ -137,6 +148,17 @@ class prometheus_cd::main::dirs (
       seltype  => etc_t,
       seluser  => system_u,
     }
+    # service systemfile directory
+    file { $ps_system_file_dir:
+      ensure   => directory,
+      owner    => 'root',
+      group    => 'root',
+      mode     => '0755',
+      selrange => s0,
+      selrole  => object_r,
+      seltype  => systemd_unit_file_t,
+      seluser  => unconfined_u,
+    }
   }
 }
diff --git a/doc/puppet_classes/prometheus_cd_3A_3Amain_3A_3Afiles.html b/doc/puppet_classes/prometheus_cd_3A_3Amain_3A_3Afiles.html index 3d626a5..9d95201 100644 --- a/doc/puppet_classes/prometheus_cd_3A_3Amain_3A_3Afiles.html +++ b/doc/puppet_classes/prometheus_cd_3A_3Amain_3A_3Afiles.html @@ -118,15 +118,27 @@ 20 21 22 -23 +23 +24 +25 +26 +27 +28 +29 +30 +31 +32 +33 +34 +35
# File 'manifests/main/files.pp', line 6
 
 class prometheus_cd::main::files (
 ) inherits prometheus_cd::params {
-  require prometheus_cd::main::dirs
-  if ($ps_prom_host == $fqdn) and ($manage_prometheus == true)  {
+    if ($ps_prom_host == $fqdn) and ($manage_prometheus == true)  {
+    require prometheus_cd::main::dirs
     file { $ps_main_file:
       ensure   => file,
       owner    => 'root',
@@ -139,6 +151,18 @@ class prometheus_cd::main::files (
       content  => template('prometheus_cd/prometheus.yml.erb'),
       notify   => Service[$ps_prom_service],
     }
+    file { $ps_system_service_file:
+      ensure   => file,
+      owner    => 'root',
+      group    => 'root',
+      mode     => '0644',
+      selrange => s0,
+      selrole  => object_r,
+      seltype  => systemd_unit_file_t,
+      seluser  => unconfined_u,
+      content  => template('prometheus_cd/override.conf.erb'),
+      notify   => Service[$ps_prom_service],
+    }
   }
 }
diff --git a/doc/puppet_classes/prometheus_cd_3A_3Aparams.html b/doc/puppet_classes/prometheus_cd_3A_3Aparams.html index 651cb71..b70075d 100644 --- a/doc/puppet_classes/prometheus_cd_3A_3Aparams.html +++ b/doc/puppet_classes/prometheus_cd_3A_3Aparams.html @@ -359,7 +359,9 @@ 54 55 56 -57 +57 +58 +59
# File 'manifests/params.pp', line 17
@@ -394,9 +396,11 @@ class prometheus_cd::params (
 
   # dirs
   $ps_main_dir            = '/etc/prometheus'
+  $ps_system_file_dir     = '/etc/systemd/system/prometheus.service.d'
 
   # files
   $ps_main_file           = "${ps_main_dir}/prometheus.yml"
+  $ps_system_service_file = "${ps_system_file_dir}/override.conf"
 
   # services
   $ps_prom_service        = 'prometheus'