ansible-role-grafana/templates/apache2-site.conf

27 lines
873 B
Text
Raw Normal View History

2022-12-27 10:43:32 +01:00
<VirtualHost *:80>
2023-11-20 11:47:05 +01:00
ServerName {{ grafana_domain }}
Redirect permanent / https://{{ grafana_domain }}/
2022-12-27 10:43:32 +01:00
</VirtualHost>
<IfModule mod_ssl.c>
<VirtualHost *:443>
2023-11-20 11:47:05 +01:00
ServerName {{ grafana_domain }}
2022-12-27 10:43:32 +01:00
Protocols h2 http/1.1
DocumentRoot /var/www/html
IncludeOptional /etc/apache2/conf-available/add-headers.conf
ErrorLog ${APACHE_LOG_DIR}/grafana.error.log
#CustomLog ${APACHE_LOG_DIR}/grafana.access.log combined
LogLevel Error
SSLEngine On
2023-11-20 11:47:05 +01:00
SSLCertificateFile /var/lib/dehydrated/certs/{{ grafana_domain }}/fullchain.pem
SSLCertificateKeyFile /var/lib/dehydrated/certs/{{ grafana_domain }}/privkey.pem
2022-12-27 10:43:32 +01:00
ProxyPreserveHost On
ProxyPass /.well-known !
ProxyPass / http://127.0.0.1:3000/
ProxyPassReverse / http://127.0.0.1:3000/
</VirtualHost>
</IfModule>