Skip to content

Commit

Permalink
Merge pull request #149 from reef-technologies/expose_business_metric
Browse files Browse the repository at this point in the history
properly secure /business-metrics endpoint
  • Loading branch information
mjurbanski-reef authored Dec 6, 2023
2 parents f944782 + 566252e commit 1d85534
Showing 1 changed file with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,10 @@ server {
location /metrics {
return 404;
}

location /business-metrics {
return 404;
}
{% endif %}

location / {
Expand Down Expand Up @@ -160,6 +164,14 @@ server {
proxy_pass http://app:8000/metrics;
}

location /business-metrics {
proxy_pass_header Server;
proxy_redirect off;
proxy_set_header Host $http_host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X_SCHEME $scheme;
proxy_pass http://app:8000/business-metrics;
}
}
{%- endif %}

Expand Down

0 comments on commit 1d85534

Please sign in to comment.