Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5b393d6194
|
+1
-3
@@ -5,6 +5,4 @@ services:
|
||||
- METRICS_ENABLED=true
|
||||
deploy:
|
||||
labels:
|
||||
- "prometheus.io/scrape=true"
|
||||
- "prometheus.io/port=9205"
|
||||
- "prometheus.io/path=/metrics"
|
||||
- "prometheus.io/scrape=true"
|
||||
+3
-11
@@ -184,24 +184,16 @@ http {
|
||||
location / {
|
||||
try_files $uri $uri/ /index.php$request_uri;
|
||||
}
|
||||
}
|
||||
|
||||
{{ if env "METRICS_ENABLED" }}
|
||||
server {
|
||||
listen 9205;
|
||||
|
||||
{{ if env "METRICS_ENABLED" }}
|
||||
location = /metrics {
|
||||
include fastcgi_params;
|
||||
fastcgi_param SCRIPT_FILENAME /var/www/html/index.php;
|
||||
fastcgi_param SCRIPT_FILENAME $document_root/index.php;
|
||||
fastcgi_param SCRIPT_NAME /index.php;
|
||||
fastcgi_param REQUEST_URI /metrics;
|
||||
fastcgi_param HTTP_HOST {{ env "DOMAIN" }};
|
||||
fastcgi_pass php-handler;
|
||||
}
|
||||
|
||||
location / {
|
||||
return 404;
|
||||
}
|
||||
{{ end }}
|
||||
}
|
||||
{{ end }}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user