From f5474f6f0efd20fa1976080202563b082b4bdc32 Mon Sep 17 00:00:00 2001 From: Jacob Babor Date: Tue, 9 Jul 2024 18:31:02 -0500 Subject: [PATCH] Add grafana matrix bridge that's super dope --- inventories/production/group_vars/all.yml | 10 ++++++++++ playbooks/tasks/web/grafana.yml | 12 ++++++++++++ 2 files changed, 22 insertions(+) diff --git a/inventories/production/group_vars/all.yml b/inventories/production/group_vars/all.yml index 2d7f41b..9b2f7dd 100644 --- a/inventories/production/group_vars/all.yml +++ b/inventories/production/group_vars/all.yml @@ -150,6 +150,16 @@ secret_gitlab_db_pass: !vault | 3365636636316534660a373562346462363935393565366636353061343932663763663532383565 36666438366337303362373838626234363266646132363235323436653131363735 +# For Grafana +secret_grafana_matrix_token: !vault | + $ANSIBLE_VAULT;1.1;AES256 + 62313634386364663564353664656437623863366137343938666635663638313464663838343135 + 6361366536363232396434333136653632376539343432390a623033636534313865306465373563 + 31343565343937376336393263616134373333336237623166333966633639646535613234316638 + 6634313534336635610a373363313737643165346264333736316362316438376662643665333661 + 30326666616362366133396562323433323435613232666337336430623230383765346333343232 + 3765346238303835633337636233376263366130303436336439 + # For Nagios secret_nagios_admin_pass: !vault | $ANSIBLE_VAULT;1.1;AES256 diff --git a/playbooks/tasks/web/grafana.yml b/playbooks/tasks/web/grafana.yml index 860d7a8..e97e641 100644 --- a/playbooks/tasks/web/grafana.yml +++ b/playbooks/tasks/web/grafana.yml @@ -28,3 +28,15 @@ - /data/grafana/storage:/var/lib/grafana - /data/grafana/logs:/var/log/grafana tags: [ docker, grafana, monitoring ] +- name: docker deploy grafana matrix bridge + docker_container: + name: grafana-matrix-bridge + image: registry.gitlab.com/hectorjsmith/grafana-matrix-forwarder:latest + env: + GMF_MATRIX_USER: "@grafana:desu.ltd" + GMF_MATRIX_PASSWORD: "{{ secret_grafana_matrix_token }}" + GMF_MATRIX_HOMESERVER: matrix.desu.ltd + networks: + - name: web + aliases: [ "grafana-matrix-bridge" ] + tags: [ docker, grafana, monitoring, bridge, matrix ]