From 69a80aea9e07a2495d0a5ce67f8305add05ff10f Mon Sep 17 00:00:00 2001 From: Guillaume Abrioux Date: Wed, 2 Jun 2021 11:05:07 +0200 Subject: [PATCH] dashboard: set cookie_secure in grafana When using grafana behind https `cookie_secure` should be set to `true`. Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1966880 Signed-off-by: Guillaume Abrioux (cherry picked from commit 4daed1f137a4c61940abd9ae2db179fafd8de17a) --- roles/ceph-grafana/templates/grafana.ini.j2 | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/roles/ceph-grafana/templates/grafana.ini.j2 b/roles/ceph-grafana/templates/grafana.ini.j2 index 61ef46c09..1d2fbc14c 100644 --- a/roles/ceph-grafana/templates/grafana.ini.j2 +++ b/roles/ceph-grafana/templates/grafana.ini.j2 @@ -27,3 +27,8 @@ http_addr = {{ grafana_server_addr }} admin_user = {{ grafana_admin_user }} admin_password = {{ grafana_admin_password }} allow_embedding = {{ grafana_allow_embedding }} + +{% if dashboard_protocol == 'https' %} +[session] +cookie_secure = true +{% endif %}