forked from mtusi2026/mtusi2026lab7
73 lines
2.0 KiB
Plaintext
73 lines
2.0 KiB
Plaintext
resolver 127.0.0.11 valid=10s ipv6=off;
|
|
|
|
map $ssl_client_s_dn $telemetry_client_ok {
|
|
default 0;
|
|
"~CN=otel-collector(,|$)" 1;
|
|
"~CN=grafana(,|$)" 1;
|
|
}
|
|
|
|
server {
|
|
listen 4318 ssl;
|
|
server_name tempo.lab.internal;
|
|
server_tokens off;
|
|
ssl_certificate /certs/telemetry.crt;
|
|
ssl_certificate_key /certs/telemetry.key;
|
|
ssl_client_certificate /certs/ca.crt;
|
|
ssl_verify_client on;
|
|
ssl_protocols TLSv1.2 TLSv1.3;
|
|
client_max_body_size 20m;
|
|
access_log off;
|
|
if ($telemetry_client_ok = 0) { return 403; }
|
|
location / {
|
|
set $upstream tempo:4318;
|
|
proxy_pass http://$upstream;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Host $host;
|
|
proxy_set_header Content-Type $content_type;
|
|
proxy_set_header Connection "";
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen 3200 ssl;
|
|
server_name tempo.lab.internal;
|
|
server_tokens off;
|
|
ssl_certificate /certs/telemetry.crt;
|
|
ssl_certificate_key /certs/telemetry.key;
|
|
ssl_client_certificate /certs/ca.crt;
|
|
ssl_verify_client on;
|
|
ssl_protocols TLSv1.2 TLSv1.3;
|
|
client_max_body_size 20m;
|
|
access_log off;
|
|
if ($telemetry_client_ok = 0) { return 403; }
|
|
location / {
|
|
set $upstream tempo:3200;
|
|
proxy_pass http://$upstream;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Host $host;
|
|
proxy_set_header Connection "";
|
|
}
|
|
}
|
|
|
|
server {
|
|
listen 3100 ssl;
|
|
server_name loki.lab.internal;
|
|
server_tokens off;
|
|
ssl_certificate /certs/telemetry.crt;
|
|
ssl_certificate_key /certs/telemetry.key;
|
|
ssl_client_certificate /certs/ca.crt;
|
|
ssl_verify_client on;
|
|
ssl_protocols TLSv1.2 TLSv1.3;
|
|
client_max_body_size 20m;
|
|
access_log off;
|
|
if ($telemetry_client_ok = 0) { return 403; }
|
|
location / {
|
|
set $upstream loki:3100;
|
|
proxy_pass http://$upstream;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Host $host;
|
|
proxy_set_header Content-Type $content_type;
|
|
proxy_set_header Connection "";
|
|
}
|
|
}
|