2019-01-01 19:44:04 +00:00
|
|
|
---
|
2020-03-30 20:40:19 +00:00
|
|
|
- name: Converge
|
|
|
|
hosts: all
|
|
|
|
roles:
|
|
|
|
- ansible-role-sensu
|
2019-01-01 19:44:04 +00:00
|
|
|
vars:
|
2020-03-30 20:40:19 +00:00
|
|
|
sensu_repository_system: ubuntu
|
|
|
|
sensu_repository_release: xenial
|
2019-01-01 19:44:04 +00:00
|
|
|
sensu_backend: yes
|
2019-03-13 20:45:02 +00:00
|
|
|
sensu_agent_redact:
|
|
|
|
- supersecret
|
2019-01-01 19:44:04 +00:00
|
|
|
sensu_agent_plugins:
|
|
|
|
- name: sensu-plugins-disk-checks
|
|
|
|
version: 3.1.1
|
|
|
|
sensu_agent_labels:
|
|
|
|
test: coucou
|
2019-03-13 20:45:02 +00:00
|
|
|
supersecret: password
|
2019-01-01 19:44:04 +00:00
|
|
|
sensu_namespaces:
|
2019-02-15 19:09:49 +00:00
|
|
|
- name: production
|
|
|
|
- name: dev
|
2019-01-01 19:44:04 +00:00
|
|
|
sensu_users:
|
|
|
|
- name: johndoe
|
|
|
|
password: secret1234
|
|
|
|
groups:
|
|
|
|
- devops
|
|
|
|
- users
|
|
|
|
sensu_assets:
|
|
|
|
- name: superasset
|
|
|
|
url: http://localhost/test.sh
|
|
|
|
sha512: >
|
|
|
|
cf83e1357eefb8bdf1542850d66d8007d620e4050b5715dc83f4a921d36ce9ce
|
|
|
|
47d0d13c5d85f2b0ff8318d2877eec2f63b931bd47417a81a538327af927da3e
|
2019-02-15 19:09:49 +00:00
|
|
|
namespaces:
|
|
|
|
- production
|
|
|
|
- dev
|
2019-03-13 22:16:50 +00:00
|
|
|
sensu_mutators:
|
|
|
|
- name: transform
|
|
|
|
command: /path/value_to_csv
|
|
|
|
namespaces:
|
|
|
|
- production
|
|
|
|
- dev
|
2019-01-01 19:44:04 +00:00
|
|
|
sensu_handlers:
|
|
|
|
- name: mail
|
|
|
|
command: echo test | mail -s coucou
|
2019-02-15 19:09:49 +00:00
|
|
|
namespaces:
|
|
|
|
- production
|
|
|
|
- dev
|
2019-01-01 19:44:04 +00:00
|
|
|
sensu_filters:
|
|
|
|
- name: state_changed
|
|
|
|
expressions:
|
|
|
|
- event.check.occurrences == 1
|
2019-02-15 19:09:49 +00:00
|
|
|
namespaces:
|
|
|
|
- production
|
|
|
|
- dev
|
2020-08-09 06:02:10 +00:00
|
|
|
sensu_hooks:
|
|
|
|
- name: restart-apache
|
|
|
|
command: /etc/init.d/apache2 restart
|
|
|
|
namespaces:
|
|
|
|
- production
|
|
|
|
- dev
|
2019-01-01 19:44:04 +00:00
|
|
|
sensu_checks:
|
|
|
|
- name: ping
|
|
|
|
command: ping -c 1 127.0.0.1
|
2019-05-09 09:08:36 +00:00
|
|
|
labels:
|
|
|
|
ping_warning: '200'
|
2019-01-01 19:44:04 +00:00
|
|
|
subscriptions:
|
|
|
|
- linux
|
2019-02-15 19:09:49 +00:00
|
|
|
namespaces:
|
|
|
|
- production
|
|
|
|
- dev
|
2019-01-01 19:44:04 +00:00
|
|
|
sensu_cluster_roles:
|
|
|
|
- name: superview
|
|
|
|
rules:
|
|
|
|
- verbs:
|
|
|
|
- get
|
|
|
|
- list
|
|
|
|
resources:
|
|
|
|
- '*'
|