Merge branch 'master' into 'master'

Master

See merge request unitoo/sys/dot-files!3
This commit is contained in:
Claudio Maradonna 2021-06-26 10:47:09 +00:00
commit 0918c4246a
13 changed files with 59 additions and 3 deletions

View file

@ -1,4 +1,6 @@
<VirtualHost *:443>
# YOUR CONFIG
# Redirect all request to a 503 return code when in maintenance mode
ErrorDocument 503 /maintenance/index.html
RewriteEngine on
@ -12,4 +14,5 @@
RewriteCond /var/www/maintenance/ALL !-f
RewriteCond /var/www/maintenance/%{SERVER_NAME} !-f
RewriteRule ^/maintenance/index.html$ / [R,L]
</VirtualHost>

View file

@ -0,0 +1,7 @@
## YOUR CONFIG HERE
<IfModule alias_module>
## OTHER CONFIG HERE
Alias "/maintenance" "/var/www/maintenance"
</IfModule>

View file

@ -0,0 +1,4 @@
## MAIN CONFIG HERE
ServerTokens Prod
ServerSignature Off

View file

@ -0,0 +1,8 @@
## MAIN CONFIG HERE
<Location "/server-status">
SetHandler server-status
Order deny,allow
Deny from all
Allow from 127.0.0.1
</Location>

View file

@ -10,7 +10,7 @@
</style>
<article>
<img src="maintenance.png" height=270>
<img src="maintenance/index.png" height=270>
<h1>We&rsquo;ll be back soon!</h1>
<div>
<p>We&rsquo;re performing some hacks at the moment.

View file

Before

Width:  |  Height:  |  Size: 55 KiB

After

Width:  |  Height:  |  Size: 55 KiB

View file

@ -1,5 +1,5 @@
...
## OTHER CONFIG
password_encryption = scram-sha-256
...
## END CONFIG

View file

@ -0,0 +1 @@
ARGS='--scrape_uri="http://127.0.0.1/server-status?auto"'

View file

@ -0,0 +1 @@
ARGS="-nginx.scrape-uri http://127.0.0.1:80/stub_status"

View file

@ -0,0 +1,2 @@
# peer mode
DATA_SOURCE_NAME='host=/var/run/postgresql sslmode=disable'

View file

@ -0,0 +1,15 @@
[Unit]
Description=Prometheus exporter for Apache
Documentation=https://github.com/Lusitaniae/apache_exporter
Wants=network-online.target
After=network-online.target
[Service]
User=root
Group=root
Type=simple
EnvironmentFile=/etc/default/prometheus-apache-exporter
ExecStart=/usr/bin/apache_exporter $ARGS
[Install]
WantedBy=multi-user.target

View file

@ -0,0 +1,15 @@
[Unit]
Description=Prometheus exporter for MariaDB
Documentation=https://github.com/prometheus/mysqld_exporter
Wants=network-online.target
After=network-online.target
[Service]
User=root
Group=root
Type=simple
EnvironmentFile=/etc/default/prometheus-mariadb-exporter
ExecStart=/usr/bin/mysqld_exporter $ARGS
[Install]
WantedBy=multi-user.target