## Tags
* access: Any user / ssh access tasks
+* monitoring: Any tasks related to installing or configuring monitoring services
* slow: Any tasks that may take a long time
### Example: Skip slow tasks
---
+common_prometheus_node_exporter_args: "--log.level=error --no-collector.nfsd"
+
lxd_cluster_ip: 172.18.0.190
lxd_cluster:
server_name: ci-host-amd64-1a
common_certificate_key_path_prefix: '/etc/ssl/private'
common_certificate_deploy_combined_pem: true
+common_prometheus_node_exporter_args: "--log.level=error"
common_install_promtail: false
common_promtail_client: 'http://graph01:3500/loki/api/v1/push'
# Setup/install tasks.
- ansible.builtin.include_tasks: setup-RedHat.yml
+ tags:
+ - always
when: ansible_os_family in ['RedHat', 'Rocky']
- ansible.builtin.include_tasks: setup-Debian.yml
+ tags:
+ - always
when: ansible_os_family == 'Debian'
- ansible.builtin.include_tasks: setup-Alpine.yml
+ tags:
+ - always
when: ansible_os_family == 'Alpine'
- ansible.builtin.include_tasks: setup-Suse.yml
+ tags:
+ - always
when: ansible_os_family == 'Suse'
- ansible.builtin.include_tasks: setup-Windows.yml
+ tags:
+ - always
when: ansible_os_family == 'Windows'
# Setup user accounts
- ansible.builtin.include_tasks: users.yml
+ tags:
+ - always
tags:
- access
when: ansible_os_family != 'Windows'
- ansible.builtin.include_tasks: users-Windows.yml
+ tags:
+ - always
tags:
- access
when: ansible_os_family == 'Windows'
mode: '0644'
- name: Install prometheus node exporter for physical hosts
when: "'hosts' in group_names"
- ansible.builtin.apt:
- name:
- - prometheus-node-exporter
- - prometheus-node-exporter-collectors
+ tags:
+ - monitoring
+ block:
+ - ansible.builtin.apt:
+ name:
+ - prometheus-node-exporter
+ - prometheus-node-exporter-collectors
+ - ansible.builtin.lineinfile:
+ line: "ARGS={{common_prometheus_node_exporter_args|quote}}"
+ path: /etc/default/prometheus-node-exporter
+ register: node_exporter_config
+ - when: node_exporter_config.changed
+ ansible.builtin.service:
+ name: prometheus-node-exporter
+ state: restarted
+ enabled: true
- name: Work-around for git hanging during checkouts
# @see https://support.efficios.com/issues/1532
value: 'HTTP/1.1'
- when: common_install_promtail
+ tags:
+ - monitoring
block:
- name: Add apt source
block: