openvibers/openvibe.services Commits
Services: nginx refuses /internal/ and /metrics case-insensitively (#17)
Changes
@@@ -109,8 +109,8 @@ server {}# ── Prometheus metrics: host-local scrapers only (http://127.0.0.1:4930/metrics) ──-- location = /metrics { return 404; }-- location /internal/ { return 404; }++ location ~* ^/metrics(/|$) { return 404; }++ location ~* ^/internal(/|$) { return 404; }# ── Pages, docs, robots.txt, sitemap, static assets ─────location / {
@@ -109,8 +109,8 @@ server {
@@ -109,8 +109,8 @@ server {
}
}
# ── Prometheus metrics: host-local scrapers only (http://127.0.0.1:4930/metrics) ──
# ── Prometheus metrics: host-local scrapers only (http://127.0.0.1:4930/metrics) ──
- location = /metrics { return 404; }
- location /internal/ { return 404; }
+ location ~* ^/metrics(/|$) { return 404; }
+ location ~* ^/internal(/|$) { return 404; }
# ── Pages, docs, robots.txt, sitemap, static assets ─────
# ── Pages, docs, robots.txt, sitemap, static assets ─────
location / {
location / {