This commit is contained in:
phil 2023-11-20 11:47:05 +01:00
parent 90132f42d5
commit 9d49e05e12
12 changed files with 56 additions and 62 deletions

View file

@ -1,11 +1,11 @@
<VirtualHost *:80>
ServerName {{ grafana.domain }}
Redirect permanent / https://{{ grafana.domain }}/
ServerName {{ grafana_domain }}
Redirect permanent / https://{{ grafana_domain }}/
</VirtualHost>
<IfModule mod_ssl.c>
<VirtualHost *:443>
ServerName {{ grafana.domain }}
ServerName {{ grafana_domain }}
Protocols h2 http/1.1
DocumentRoot /var/www/html
IncludeOptional /etc/apache2/conf-available/add-headers.conf
@ -15,8 +15,8 @@
LogLevel Error
SSLEngine On
SSLCertificateFile /var/lib/dehydrated/certs/{{ grafana.domain }}/fullchain.pem
SSLCertificateKeyFile /var/lib/dehydrated/certs/{{ grafana.domain }}/privkey.pem
SSLCertificateFile /var/lib/dehydrated/certs/{{ grafana_domain }}/fullchain.pem
SSLCertificateKeyFile /var/lib/dehydrated/certs/{{ grafana_domain }}/privkey.pem
ProxyPreserveHost On
ProxyPass /.well-known !

View file

@ -2,13 +2,13 @@
[server]
protocoll = https
domain = {{ grafana.domain }}
domain = {{ grafana_domain }}
enforce_domain = true
root_url = https://{{ grafana.domain }}
root_url = https://{{ grafana_domain }}
[database]
type = mysql
host = 127.0.0.1:3306
host = {{ database_host }}:3306
name = {{ grafana_db }}
user = {{ grafana_db_user }}
password = {{ grafana_db_password }}
@ -48,11 +48,10 @@ rendering_language = de-DE
signout_redirect_url = {{ grafana_auth_signout_redirect_url }}
oauth_auto_login = false
{% if grafana_auth_generic_oauth_enabled is defined and grafana_auth_generic_oauth_enabled %}
[auth.generic_oauth]
name = {{ grafana_auth_generic_oauth_name }}
{% if grafana_auth_generic_oauth_enabled is defined and grafana_auth_generic_oauth_enabled %}
enabled = true
{% endif %}
client_id = {{ grafana_auth_generic_oauth_client_id }}
client_secret = {{ grafana_auth_generic_oauth_client_secret }}
scopes = openid email profile
@ -60,3 +59,4 @@ auth_url = {{ grafana_auth_generic_oauth_auth_url }}
token_url = {{ grafana_auth_generic_oauth_token_url }}
api_url = {{ grafana_auth_generic_oauth_api_url }}
role_attribute_path = {{ grafana_auth_generic_oauth_role_attribute_path }}
{% endif %}