aboutsummaryrefslogtreecommitdiffstats
path: root/roles
diff options
context:
space:
mode:
Diffstat (limited to 'roles')
-rw-r--r--roles/grafana/tasks/main.yml8
-rw-r--r--roles/grafana/vars/main.yml5
2 files changed, 11 insertions, 2 deletions
diff --git a/roles/grafana/tasks/main.yml b/roles/grafana/tasks/main.yml
index 5df8fa3..919f15e 100644
--- a/roles/grafana/tasks/main.yml
+++ b/roles/grafana/tasks/main.yml
@@ -7,6 +7,14 @@
- name: install grafana
package: name=grafana state=present
+- name: ensure grafana dir exists
+ file:
+ path: "{{ grafana_dir }}"
+ owner: "{{ grafana_user }}"
+ group: "{{ grafana_group }}"
+ mode: 0640
+ state: directory
+
- name: generate grafana configuration
template:
src: grafana.ini.j2
diff --git a/roles/grafana/vars/main.yml b/roles/grafana/vars/main.yml
index b980ba8..9e15d9c 100644
--- a/roles/grafana/vars/main.yml
+++ b/roles/grafana/vars/main.yml
@@ -4,10 +4,11 @@
---
+grafana_dir: /data/grafana
grafana_port: 3001
grafana_port_out: 3000
-grafana_user: grafana
-grafana_group: grafana
+grafana_user: _grafana
+grafana_group: _grafana
grafana_db: sqlite
grafana_instance_name: "rgoncalves.se monitoring"
remember that computers suck.