This repository was archived by the owner on Mar 6, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 9 files changed +45
-43
lines changed Expand file tree Collapse file tree 9 files changed +45
-43
lines changed Original file line number Diff line number Diff line change 1
1
---
2
- - name : Install dependencies
3
- package :
4
- name : " {{ item }}"
5
- state : present
6
- register : _install_dep_packages
7
- until : _install_dep_packages is success
8
- retries : 5
9
- delay : 2
10
- with_items : " {{ node_exporter_dependencies }}"
11
-
12
2
- name : Create the node_exporter group
13
3
group :
14
4
name : " {{ node_exporter_system_group }}"
Original file line number Diff line number Diff line change 1
1
---
2
- - name : Gather variables for each operating system
3
- include_vars : " {{ item }}"
4
- with_first_found :
5
- - " {{ ansible_distribution | lower }}-{{ ansible_distribution_version | lower }}.yml"
6
- - " {{ ansible_distribution | lower }}-{{ ansible_distribution_major_version | lower }}.yml"
7
- - " {{ ansible_os_family | lower }}-{{ ansible_distribution_major_version | lower }}.yml"
8
- - " {{ ansible_distribution_file_variety | lower }}.yml"
9
- - " {{ ansible_distribution | lower }}.yml"
10
- - " {{ ansible_os_family | lower }}.yml"
11
- tags :
12
- - node_exporter_install
13
- - node_exporter_configure
14
- - node_exporter_run
15
-
16
2
- import_tasks : preflight.yml
17
3
tags :
18
4
- node_exporter_install
25
11
tags :
26
12
- node_exporter_install
27
13
14
+ - import_tasks : selinux.yml
15
+ become : true
16
+ when : ansible_selinux.status == "enabled"
17
+ tags :
18
+ - node_exporter_configure
19
+
28
20
- import_tasks : configure.yml
29
21
become : true
30
22
tags :
Original file line number Diff line number Diff line change
1
+ ---
2
+ - name : Install selinux python packages [RHEL]
3
+ package :
4
+ name :
5
+ - " {{ ( (ansible_facts.distribution_major_version | int) < 8) | ternary('libselinux-python','python3-libselinux') }}"
6
+ - " {{ ( (ansible_facts.distribution_major_version | int) < 8) | ternary('libselinux-python','python3-policycoreutils') }}"
7
+ state : present
8
+ register : _install_selinux_packages
9
+ until : _install_selinux_packages is success
10
+ retries : 5
11
+ delay : 2
12
+ when :
13
+ - (ansible_distribution | lower == "redhat") or
14
+ (ansible_distribution | lower == "centos")
15
+
16
+ - name : Install selinux python packages [Fedora]
17
+ package :
18
+ name :
19
+ - " {{ ( (ansible_facts.distribution_major_version | int) < 29) | ternary('libselinux-python','python3-libselinux') }}"
20
+ - " {{ ( (ansible_facts.distribution_major_version | int) < 29) | ternary('libselinux-python','python3-policycoreutils') }}"
21
+ state : present
22
+ register : _install_selinux_packages
23
+ until : _install_selinux_packages is success
24
+ retries : 5
25
+ delay : 2
26
+
27
+ when :
28
+ - ansible_distribution | lower == "fedora"
29
+
30
+ - name : Install selinux python packages [clearlinux]
31
+ package :
32
+ name : sysadmin-basic
33
+ state : present
34
+ register : _install_selinux_packages
35
+ until : _install_selinux_packages is success
36
+ retries : 5
37
+ delay : 2
38
+ when :
39
+ - ansible_distribution | lower = "clearlinux"
Load Diff This file was deleted.
Load Diff This file was deleted.
Load Diff This file was deleted.
Load Diff This file was deleted.
Load Diff This file was deleted.
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments