From 3c38d3c321e03e7af48efbec8aa6c5270e85fe32 Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Fri, 3 Feb 2023 17:16:38 +0100 Subject: add promzone-test --- inventory/group_vars/promzone-test/vars.yml | 28 +++++++++++++++ inventory/host_vars/ch-testvm-phoebe.yml | 22 ++++++++++++ inventory/host_vars/ch-testvm-prometheus.yml | 51 ++++++++++++++++++++++++++++ inventory/hosts.ini | 7 ++++ 4 files changed, 108 insertions(+) create mode 100644 inventory/group_vars/promzone-test/vars.yml (limited to 'inventory') diff --git a/inventory/group_vars/promzone-test/vars.yml b/inventory/group_vars/promzone-test/vars.yml new file mode 100644 index 00000000..83110df7 --- /dev/null +++ b/inventory/group_vars/promzone-test/vars.yml @@ -0,0 +1,28 @@ +--- +prometheus_scrape_endpoint: "{{ network.primary.address | ansible.utils.ipaddr('address') }}:9999" + +prometheus_exporters_extra: [] +prometheus_exporters_default: + - node + +prometheus_exporter_node_version: 1.5.0 +prometheus_exporter_ipmi_version: 1.6.1 +prometheus_exporter_ssl_version: 2.4.2 +prometheus_exporter_blackbox_version: 0.23.0 +prometheus_exporter_nut_version: 2.5.2 +prometheus_exporter_smokeping_version: 0.6.1 +prometheus_exporter_bind_version: 0.6.0 + +prometheus_server_version: 2.41.0 +prometheus_alertmanager_version: 0.25.0 + +prometheus_server: ch-testvm-prometheus +prometheus_server_jobs: + - node + - blackbox + - blackbox/probe + - ssl + - ssl/probe + +prometheus_zone_name: chaos@test +prometheus_zone_targets: "{{ groups['promzone-test'] }}" diff --git a/inventory/host_vars/ch-testvm-phoebe.yml b/inventory/host_vars/ch-testvm-phoebe.yml index 109f820f..94c9eca3 100644 --- a/inventory/host_vars/ch-testvm-phoebe.yml +++ b/inventory/host_vars/ch-testvm-phoebe.yml @@ -37,3 +37,25 @@ network: - *_network_primary_ - name: iot0 address: "{{ network_zones.iot.prefix | ansible.utils.ipaddr(network_zones.iot.offsets[inventory_hostname]) }}" + +ntp_variant: systemd-timesyncd + + +spreadspace_apt_repo_components: + - prometheus + + +prometheus_exporters_extra: + - ssl + +prometheus_job_multitarget_blackbox__probe: + ch-testvm-prometheus: + - instance: "ssh-{{ inventory_hostname }}" + target: "{{ network_zones.svc.prefix | ansible.utils.ipaddr(network_zones.svc.offsets[inventory_hostname]) | ansible.utils.ipaddr('address') }}:{{ ansible_port | default(22) }}" + module: ssh_banner + +prometheus_job_multitarget_ssl__probe: + ch-testvm-phoebe: + - instance: "sslcert-prometheus-{{ inventory_hostname }}" + target: "/etc/ssl/prometheus/**/*.pem" + module: file diff --git a/inventory/host_vars/ch-testvm-prometheus.yml b/inventory/host_vars/ch-testvm-prometheus.yml index f95366b0..034b5d67 100644 --- a/inventory/host_vars/ch-testvm-prometheus.yml +++ b/inventory/host_vars/ch-testvm-prometheus.yml @@ -33,3 +33,54 @@ network: gateway: "{{ network_zones.svc.prefix | ansible.utils.ipaddr(network_zones.svc.offsets['ch-gw-lan']) | ansible.utils.ipaddr('address') }}" interfaces: - *_network_primary_ + +ntp_variant: systemd-timesyncd + + +spreadspace_apt_repo_components: + - prometheus + + +prometheus_server_storage: + type: lvm + vg: "{{ host_name }}" + lv: prometheus + size: 1G + fs: ext4 + +prometheus_server_external_labels: + environment: chaos-at-test + monitor: "{{ inventory_hostname }}" + +prometheus_server_web_external_url: "http://{{ network.primary.address | ansible.utils.ipaddr('address') }}/prometheus/" + +prometheus_server_auth_users: + server: "{{ vault_prometheus_server_auth_user_passwords['server'] }}" + admin: "{{ vault_prometheus_server_auth_user_passwords['admin'] }}" + +prometheus_server_selfscraping_auth: + username: server + password: "{{ vault_prometheus_server_auth_user_passwords['server'] }}" + + +prometheus_exporters_extra: + - blackbox + - ssl + + +prometheus_job_multitarget_blackbox__probe: + ch-testvm-prometheus: + - instance: "ssh-{{ inventory_hostname }}" + target: "{{ network_zones.svc.prefix | ansible.utils.ipaddr(network_zones.svc.offsets[inventory_hostname]) | ansible.utils.ipaddr('address') }}:{{ ansible_port | default(22) }}" + module: ssh_banner + +prometheus_job_multitarget_ssl__probe: + ch-testvm-prometheus: + - instance: "sslcert-prometheus-{{ inventory_hostname }}" + target: "/etc/ssl/prometheus/**/*.pem" + module: file + + +monitoring_landingpage_hostnames: + - "mon-test.chaos-at-home.org" +monitoring_landingpage_title: "chaos@test Monitoring Host" diff --git a/inventory/hosts.ini b/inventory/hosts.ini index da3193a6..21b31e3c 100644 --- a/inventory/hosts.ini +++ b/inventory/hosts.ini @@ -460,6 +460,13 @@ ele-telesto promzone-elevate-festival-server #elevate-mediachannel +[promzone-test-server] +ch-testvm-prometheus +[promzone-test] +ch-testvm-phoebe +[promzone-test:children] +promzone-test-server + ## openvpn # [ovpnzone-test-server] -- cgit v1.2.3