]> git-server-git.apps.pok.os.sepia.ceph.com Git - cephmetrics.git/commitdiff
ceph-grafana: Set the admin users's home db 195/head
authorZack Cerza <zack@redhat.com>
Fri, 22 Jun 2018 21:58:16 +0000 (15:58 -0600)
committerZack Cerza <zack@redhat.com>
Fri, 22 Jun 2018 22:13:09 +0000 (16:13 -0600)
If a human (or API request) changes the home dashboard for the admin
account, our method of setting it at the org level will no longer be
effective. Let's keep the admin user's home dashboard set to
ceph-at-a-glance.

Signed-off-by: Zack Cerza <zack@redhat.com>
ansible/roles/ceph-grafana/tasks/push_dashboards.yml

index 3282418d29b926da240a6adbf2a7629ea3072d6a..a2b5f22ed1b7721e60ae5eef2743980241863943 100644 (file)
@@ -78,9 +78,9 @@
   register: dashboard_home
   no_log: true
 
-- name: Set the home dashboard
+- name: Set the org's home dashboard
   uri:
-    url: http://localhost:3000/api/org/preferences
+    url: "http://localhost:3000/api/{{ item }}/preferences"
     method: PUT
     user: "{{ grafana.admin_user }}"
     password: "{{ grafana.admin_password }}"
@@ -88,3 +88,6 @@
     status_code: 200
     body_format: json
     body: '{"homeDashboardId": {{ dashboard_home.json.dashboard.id }} }'
+  with_items:
+    - user
+    - org