From 3a58629e2e9383056b44a6201c8603083bf87bf7 Mon Sep 17 00:00:00 2001 From: Simon Mayer Date: Tue, 10 Sep 2024 13:02:01 +0200 Subject: [PATCH 1/4] Documentation for the monitoring role --- partition/roles/monitoring/README.md | 45 ++++++++++++++++++++++++++++ partition/roles/promtail/README.md | 16 +++++----- 2 files changed, 54 insertions(+), 7 deletions(-) create mode 100644 partition/roles/monitoring/README.md diff --git a/partition/roles/monitoring/README.md b/partition/roles/monitoring/README.md new file mode 100644 index 00000000..7278594e --- /dev/null +++ b/partition/roles/monitoring/README.md @@ -0,0 +1,45 @@ +# monitoring + +Deploys exporter in systemd-managed Docker containers. + +## Variables + +| Name | Mandatory | Description | +| ------------------------------------------------ | --------- | ----------------------------------------------------------- | +| monitoring_blackbox_exporter_etc_host_dir | | The host directory for the blackbox exporter | +| monitoring_blackbox_exporter_image_name | | Image name of the blackblox exporter | +| monitoring_blackbox_exporter_image_tag | | Image tag of the blackbox exporter | +| monitoring_blackbox_exporter_port | | Port for the blackblox exporter | +| monitoring_ipmi_exporter_etc_host_dir | | The host directory for the IPMI exporter | +| monitoring_ipmi_exporter_image_name | | Image name of the IPMI exporter | +| monitoring_ipmi_exporter_image_tag | | Image tag of the IPMI exporter | +| monitoring_ipmi_exporter_port | | Port for the IPMI exporter | +| monitoring_node_exporter_dir | | The host directory for the node exporter | +| monitoring_node_exporter_image_name | | Image name of the IPMI exporter | +| monitoring_node_exporter_image_tag | | Image tag of the IPMI exporter | +| monitoring_node_exporter_port | | Port for the IPMI exporter | +| prometheus_port | | Port for prometheus | +| prometheus_config_host_dir | | The host directory for prometheus configurations | +| prometheus_data_host_dir | | The host directory for prometheus data | +| prometheus_alertmanager_target | | Targets for the alertmanager | +| prometheus_alertmanager_basic_auth_username | | The username for the authentication to the alertmanager | +| prometheus_alertmanager_basic_auth_password | | The password for the authentication to the alertmanager | +| prometheus_remote_write | | Remote write target for prometheus | +| prometheus_frr_exporter_targets | | FRR exporter targets to scrape from | +| prometheus_metal_core_targets | | metal-core targets to scrape from | +| prometheus_node_exporter_targets | | Node exporter targets to scrape from | +| prometheus_promtail_targets | | Promtail targets to scrape from | +| prometheus_ping_targets | | Ping targets to scrape from | +| prometheus_sonic_exporter_targets | | Sonic exporter targets to scrape from | +| prometheus_blackbox_exporter_targets | | Blackbox exporter targets to scrape from | +| prometheus_lightbox_exporter_targets | | Lightbox exporter targets to scrape from | +| prometheus_lightos_smart_targets | | Lightos smart targets to scrape from | +| prometheus_hosts_content | | Available hosts for prometheus | +| prometheus_blackbox_exporter_icmp_groups | | ICMP groups for the blackbox exporter | +| prometheus_blackbox_exporter_metal_api_probe_url | | metal-api probe URL for the blackbox exporter | +| prometheus_remote_write_basic_auth_username | | The username for the prometheus remote write authentication | +| prometheus_remote_write_basic_auth_password | | The password for the prometheus remote write authentication | +| sonic_exporter_image_name | | Image name of the sonic exporter | +| sonic_exporter_image_tag | | Image tag of the sonic exporter | +| sonic_exporter_address | | Address for the sonic exporter | +| sonic_exporter_port | | Port for the sonic exporter | diff --git a/partition/roles/promtail/README.md b/partition/roles/promtail/README.md index 1149b486..60c6d9b6 100644 --- a/partition/roles/promtail/README.md +++ b/partition/roles/promtail/README.md @@ -4,10 +4,12 @@ Deploys promtail in a systemd-managed Docker container. ## Variables -| Name | Mandatory | Description | -|-----------------------------|-----------|--------------------------------------| -| promtail_config_host_dir | | The location of the promtail config | -| promtail_image_name | yes | Image version of the promtail | -| promtail_image_tag | yes | Image tag of the promtail | -| promtail_loki_push_endpoint | yes | The URL to the Loki push endpoint | -| promtail_scrape_configs | yes | A list containing the scrape configs | +| Name | Mandatory | Description | +| --------------------------------- | --------- | ------------------------------------------ | +| promtail_config_host_dir | | The location of the promtail config | +| promtail_image_name | yes | Image version of the promtail | +| promtail_image_tag | yes | Image tag of the promtail | +| promtail_loki_push_endpoint | yes | The URL to the Loki push endpoint | +| promtail_scrape_configs | yes | A list containing the scrape configs | +| promtail_loki_basic_auth_username | | The username for the client authentication | +| promtail_loki_basic_auth_password | | The password for the client authentication | From b20515f93fd2f7f315979eef2af5d4d981a14824 Mon Sep 17 00:00:00 2001 From: Simon Mayer Date: Fri, 13 Sep 2024 14:49:25 +0200 Subject: [PATCH 2/4] One README for each role --- .../monitoring/blackbox-exporter/README.md | 12 +++++++++++ .../roles/monitoring/ipmi-exporter/README.md | 12 +++++++++++ .../roles/monitoring/node-exporter/README.md | 12 +++++++++++ .../monitoring/{ => prometheus}/README.md | 20 ++----------------- .../roles/monitoring/sonic-exporter/README.md | 12 +++++++++++ 5 files changed, 50 insertions(+), 18 deletions(-) create mode 100644 partition/roles/monitoring/blackbox-exporter/README.md create mode 100644 partition/roles/monitoring/ipmi-exporter/README.md create mode 100644 partition/roles/monitoring/node-exporter/README.md rename partition/roles/monitoring/{ => prometheus}/README.md (58%) create mode 100644 partition/roles/monitoring/sonic-exporter/README.md diff --git a/partition/roles/monitoring/blackbox-exporter/README.md b/partition/roles/monitoring/blackbox-exporter/README.md new file mode 100644 index 00000000..ecb93530 --- /dev/null +++ b/partition/roles/monitoring/blackbox-exporter/README.md @@ -0,0 +1,12 @@ +# blackbox-exporter + +Deploys the blackbox-exporter in a systemd-managed Docker container. + +## Variables + +| Name | Mandatory | Description | +| ----------------------------------------- | --------- | -------------------------------------------- | +| monitoring_blackbox_exporter_etc_host_dir | | The host directory for the blackbox exporter | +| monitoring_blackbox_exporter_image_name | | Image name of the blackblox exporter | +| monitoring_blackbox_exporter_image_tag | | Image tag of the blackbox exporter | +| monitoring_blackbox_exporter_port | | Port for the blackblox exporter | diff --git a/partition/roles/monitoring/ipmi-exporter/README.md b/partition/roles/monitoring/ipmi-exporter/README.md new file mode 100644 index 00000000..6625f69b --- /dev/null +++ b/partition/roles/monitoring/ipmi-exporter/README.md @@ -0,0 +1,12 @@ +# ipmi-exporter + +Deploys the ipmi-exporter in a systemd-managed Docker container. + +## Variables + +| Name | Mandatory | Description | +| ------------------------------------- | --------- | ---------------------------------------- | +| monitoring_ipmi_exporter_etc_host_dir | | The host directory for the IPMI exporter | +| monitoring_ipmi_exporter_image_name | | Image name of the IPMI exporter | +| monitoring_ipmi_exporter_image_tag | | Image tag of the IPMI exporter | +| monitoring_ipmi_exporter_port | | Port for the IPMI exporter | diff --git a/partition/roles/monitoring/node-exporter/README.md b/partition/roles/monitoring/node-exporter/README.md new file mode 100644 index 00000000..980ddf4c --- /dev/null +++ b/partition/roles/monitoring/node-exporter/README.md @@ -0,0 +1,12 @@ +# node-exporter + +Deploys the node-exporter in a systemd-managed Docker container. + +## Variables + +| Name | Mandatory | Description | +| ----------------------------------- | --------- | ---------------------------------------- | +| monitoring_node_exporter_dir | | The host directory for the node exporter | +| monitoring_node_exporter_image_name | | Image name of the IPMI exporter | +| monitoring_node_exporter_image_tag | | Image tag of the IPMI exporter | +| monitoring_node_exporter_port | | Port for the IPMI exporter | diff --git a/partition/roles/monitoring/README.md b/partition/roles/monitoring/prometheus/README.md similarity index 58% rename from partition/roles/monitoring/README.md rename to partition/roles/monitoring/prometheus/README.md index 7278594e..950adf4e 100644 --- a/partition/roles/monitoring/README.md +++ b/partition/roles/monitoring/prometheus/README.md @@ -1,23 +1,11 @@ -# monitoring +# prometheus -Deploys exporter in systemd-managed Docker containers. +Deploys prometheus in a systemd-managed Docker container. ## Variables | Name | Mandatory | Description | | ------------------------------------------------ | --------- | ----------------------------------------------------------- | -| monitoring_blackbox_exporter_etc_host_dir | | The host directory for the blackbox exporter | -| monitoring_blackbox_exporter_image_name | | Image name of the blackblox exporter | -| monitoring_blackbox_exporter_image_tag | | Image tag of the blackbox exporter | -| monitoring_blackbox_exporter_port | | Port for the blackblox exporter | -| monitoring_ipmi_exporter_etc_host_dir | | The host directory for the IPMI exporter | -| monitoring_ipmi_exporter_image_name | | Image name of the IPMI exporter | -| monitoring_ipmi_exporter_image_tag | | Image tag of the IPMI exporter | -| monitoring_ipmi_exporter_port | | Port for the IPMI exporter | -| monitoring_node_exporter_dir | | The host directory for the node exporter | -| monitoring_node_exporter_image_name | | Image name of the IPMI exporter | -| monitoring_node_exporter_image_tag | | Image tag of the IPMI exporter | -| monitoring_node_exporter_port | | Port for the IPMI exporter | | prometheus_port | | Port for prometheus | | prometheus_config_host_dir | | The host directory for prometheus configurations | | prometheus_data_host_dir | | The host directory for prometheus data | @@ -39,7 +27,3 @@ Deploys exporter in systemd-managed Docker containers. | prometheus_blackbox_exporter_metal_api_probe_url | | metal-api probe URL for the blackbox exporter | | prometheus_remote_write_basic_auth_username | | The username for the prometheus remote write authentication | | prometheus_remote_write_basic_auth_password | | The password for the prometheus remote write authentication | -| sonic_exporter_image_name | | Image name of the sonic exporter | -| sonic_exporter_image_tag | | Image tag of the sonic exporter | -| sonic_exporter_address | | Address for the sonic exporter | -| sonic_exporter_port | | Port for the sonic exporter | diff --git a/partition/roles/monitoring/sonic-exporter/README.md b/partition/roles/monitoring/sonic-exporter/README.md new file mode 100644 index 00000000..65c4d84e --- /dev/null +++ b/partition/roles/monitoring/sonic-exporter/README.md @@ -0,0 +1,12 @@ +# sonic-exporter + +Deploys the sonic-exporter in a systemd-managed Docker container. + +## Variables + +| Name | Mandatory | Description | +| ------------------------- | --------- | -------------------------------- | +| sonic_exporter_image_name | | Image name of the sonic exporter | +| sonic_exporter_image_tag | | Image tag of the sonic exporter | +| sonic_exporter_address | | Address for the sonic exporter | +| sonic_exporter_port | | Port for the sonic exporter | From d520d25a19a800e8a6aff8aa1892290720f91b41 Mon Sep 17 00:00:00 2001 From: Simon Mayer Date: Wed, 11 Dec 2024 15:33:20 +0100 Subject: [PATCH 3/4] Implement review --- partition/roles/monitoring/blackbox-exporter/README.md | 2 ++ partition/roles/monitoring/prometheus/README.md | 7 ++++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/partition/roles/monitoring/blackbox-exporter/README.md b/partition/roles/monitoring/blackbox-exporter/README.md index ecb93530..f83a34e4 100644 --- a/partition/roles/monitoring/blackbox-exporter/README.md +++ b/partition/roles/monitoring/blackbox-exporter/README.md @@ -4,6 +4,8 @@ Deploys the blackbox-exporter in a systemd-managed Docker container. ## Variables +This role uses variables from [partition-defaults](/partition). So, make sure you define them adequately as well. + | Name | Mandatory | Description | | ----------------------------------------- | --------- | -------------------------------------------- | | monitoring_blackbox_exporter_etc_host_dir | | The host directory for the blackbox exporter | diff --git a/partition/roles/monitoring/prometheus/README.md b/partition/roles/monitoring/prometheus/README.md index 950adf4e..6fb075d3 100644 --- a/partition/roles/monitoring/prometheus/README.md +++ b/partition/roles/monitoring/prometheus/README.md @@ -4,15 +4,19 @@ Deploys prometheus in a systemd-managed Docker container. ## Variables +This role uses variables from [partition-defaults](/partition). So, make sure you define them adequately as well. + | Name | Mandatory | Description | | ------------------------------------------------ | --------- | ----------------------------------------------------------- | | prometheus_port | | Port for prometheus | +| prometheus_image_name | | Image version of the prometheus | +| prometheus_image_tag | | Image tag of the prometheus | | prometheus_config_host_dir | | The host directory for prometheus configurations | | prometheus_data_host_dir | | The host directory for prometheus data | | prometheus_alertmanager_target | | Targets for the alertmanager | | prometheus_alertmanager_basic_auth_username | | The username for the authentication to the alertmanager | | prometheus_alertmanager_basic_auth_password | | The password for the authentication to the alertmanager | -| prometheus_remote_write | | Remote write target for prometheus | +| prometheus_remote_write_url | | Remote write target for prometheus | | prometheus_frr_exporter_targets | | FRR exporter targets to scrape from | | prometheus_metal_core_targets | | metal-core targets to scrape from | | prometheus_node_exporter_targets | | Node exporter targets to scrape from | @@ -22,6 +26,7 @@ Deploys prometheus in a systemd-managed Docker container. | prometheus_blackbox_exporter_targets | | Blackbox exporter targets to scrape from | | prometheus_lightbox_exporter_targets | | Lightbox exporter targets to scrape from | | prometheus_lightos_smart_targets | | Lightos smart targets to scrape from | +| prometheus_ipmi_exporter_targets | | IPMI exporter targets to scrape from | | prometheus_hosts_content | | Available hosts for prometheus | | prometheus_blackbox_exporter_icmp_groups | | ICMP groups for the blackbox exporter | | prometheus_blackbox_exporter_metal_api_probe_url | | metal-api probe URL for the blackbox exporter | From dffc1f876956f9541e1e60e654b108db226d3a65 Mon Sep 17 00:00:00 2001 From: Simon Mayer Date: Wed, 11 Dec 2024 16:50:54 +0100 Subject: [PATCH 4/4] Make variables mandatory --- partition/roles/monitoring/prometheus/README.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/partition/roles/monitoring/prometheus/README.md b/partition/roles/monitoring/prometheus/README.md index 6fb075d3..831c7389 100644 --- a/partition/roles/monitoring/prometheus/README.md +++ b/partition/roles/monitoring/prometheus/README.md @@ -4,13 +4,14 @@ Deploys prometheus in a systemd-managed Docker container. ## Variables -This role uses variables from [partition-defaults](/partition). So, make sure you define them adequately as well. +This role uses variables from [partition-defaults](/partition). So, make sure +you define them adequately as well. | Name | Mandatory | Description | | ------------------------------------------------ | --------- | ----------------------------------------------------------- | | prometheus_port | | Port for prometheus | -| prometheus_image_name | | Image version of the prometheus | -| prometheus_image_tag | | Image tag of the prometheus | +| prometheus_image_name | yes | Image version of the prometheus | +| prometheus_image_tag | yes | Image tag of the prometheus | | prometheus_config_host_dir | | The host directory for prometheus configurations | | prometheus_data_host_dir | | The host directory for prometheus data | | prometheus_alertmanager_target | | Targets for the alertmanager |