-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathall.yml
118 lines (105 loc) · 4.31 KB
/
all.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
---
######################
# Service VIP address
######################
ansitheus_vip_address: ""
prometheus_vip_address: "{{ ansitheus_vip_address }}"
alertmanager_vip_address: "{{ ansitheus_vip_address }}"
# Get interface from the default interface: https://docs.ansible.com/ansible/latest/playbook_guide/playbooks_vars_facts.html#ansible-facts
ansitheus_network_interface: "{{ ansible_default_ipv4.interface }}"
ansitheus_config_dir: "/etc/ansitheus"
ansitheus_custom_config_dir: "{{ ansitheus_config_dir }}/config"
# The group which own node_config_directory, you can use a non-root
config_owner_user: "root"
config_owner_group: "root"
network_interface: "{{ ansitheus_network_interface }}"
api_interface: "{{ network_interface }}"
api_interface_address: "{{ hostvars[inventory_hostname]['ansible_' + api_interface]['ipv4']['address'] }}"
###################
# Haproxy Passwords
###################
keepalived_password: "{{ keepalived_password }}"
keepalived_virtual_router_id: "82"
################
# Docker options
################
docker_registry: "{{ docker_registry if docker_registry else '' }}"
docker_namespace: "{{ docker_namespace if docker_namespace else '' }}"
docker_registry_username: "{{ docker_registry_username if docker_registry_username else ''}}"
docker_registry_password: "{{ docker_registry_password if docker_registry_password else '' }}"
docker_log_driver: "json-file"
docker_log_opts:
max-size: 30m
max-file: "3"
# Docker memory limit in format <number>[<unit>]. Number is a positive integer.
# Unit can be B (byte), K (kibibyte, 1024B), M (mebibyte), G (gibibyte), T (tebibyte), or P (pebibyte).
# Omitting the unit defaults to bytes.
#
# By default, set the maximum available memory
docker_memory_limit: "{{ ansible_memtotal_mb }}M"
# Docker memory swap limit. Using swap allows the container to write excess memory
# requirements to disk when the container has exhausted all the RAM that's available
# to it. There is a performance penalty for applications that swap memory to disk often.
#
# By default, set the same value as docker_memory_limit to prevent containers from using the swap
docker_memory_swap_limit: "{{ docker_memory_limit }}"
# How much of the available CPU resources a container can use.
docker_cpus_limit: "{{ ansible_processor_count }}"
# Container global environment variables. It will be applied to all containers.
# docker_container_env:
# http_proxy: http://localhost:8000
# https_proxy: http://localhost:8000
# no_proxy: localhost, 127.0.0.1
docker_container_env: {}
##################
# Service options
##################
# Enable services
enable_common: "yes"
enable_prometheus: "yes"
enable_node_exporter: "yes"
enable_cadvisor: "yes"
enable_grafana: "yes"
enable_alertmanager: "yes"
enable_haproxy: "yes"
enable_mysqld_exporter: "no"
enable_fluentd: "no"
enable_openstack_exporter: "no"
enable_nginx_exporter: "no"
# Special variable to handle case, you want to only ONE Prometheus running instance at time.
prometheus_active_passive_mode: "no"
##################
# Port mappings
#################
prometheus_port: "9090"
alertmanager_port: "9093"
alertmanager_cluster_port: "9094"
node_exporter_port: "9100"
cadvisor_port: "8080"
grafana_port: "3000"
mysqld_exporter_port: "9104"
openstack_exporter_port: "9180"
nginx_exporter_port: "9113"
###############
# Image version
###############
prometheus_version: "3.1.0"
alertmanager_version: "0.28.0"
node_exporter_version: "1.8.2"
cadvisor_version: "0.49.2"
grafana_version: "11.4.0"
haproxy_version: "lts-alpine"
mysqld_exporter_version: "0.15.1"
fluentd_version: "1.17"
nginx_exporter_version: "1.4.1"
##########################
# Service docker namespace
##########################
prometheus_docker_namespace: "{{ docker_namespace if docker_namespace else 'prom' }}"
alertmanager_docker_namespace: "{{ docker_namespace if docker_namespace else 'prom' }}"
node_exporter_docker_namespace: "{{ docker_namespace if docker_namespace else 'prom' }}"
grafana_docker_namespace: "{{ docker_namespace if docker_namespace else 'grafana' }}"
cadvisor_docker_namespace: "{{ docker_namespace if docker_namespace else 'cadvisor' }}"
keepalived_docker_namespace: "{{ docker_namespace if docker_namespace else 'kiennt26' }}"
haproxy_docker_namespace: "{{ docker_namespace if docker_namespace else '' }}"
mysqld_exporter_docker_namespace: "{{ docker_namespace if docker_namespace else 'prom' }}"