oauth2-proxy/pkg/middleware
Sean Jones a7c8a233ba
Add Prometheus metrics endpoint
Add the Prometheus http.Handler to serve metrics at MetricsPath ("/metrics"
by default). This allows Prometheus to scrape metrics from OAuth2 Proxy.

Add a new middleware NewRequestMetrics and attach it to the preAuth
chain. This will collect metrics on all requests made to OAuth2 Proxy

Collapse some calls to Prinf() and os.Exit(1) to Fatalf as they are
equivalent. main() has a strict 50 lines limit so brevity in these
calls appreciated
2021-02-15 13:45:26 +00:00
..
testdata/metrics Add Prometheus metrics endpoint 2021-02-15 13:45:26 +00:00
basic_session.go Refactor organization of scope aware request utils 2021-01-16 13:55:48 -08:00
basic_session_test.go Refactor organization of scope aware request utils 2021-01-16 13:55:48 -08:00
headers.go Flatten array-based response headers 2021-02-03 16:48:26 -08:00
headers_test.go Flatten array-based response headers 2021-02-03 16:48:26 -08:00
healthcheck.go (#649) Remove blank helthcheck user agents and paths when setting up the healthcheck middleware 2020-07-06 14:07:38 +12:00
healthcheck_test.go (#649) Remove blank helthcheck user agents and paths when setting up the healthcheck middleware 2020-07-06 14:07:38 +12:00
jwt_session.go Refactor organization of scope aware request utils 2021-01-16 13:55:48 -08:00
jwt_session_test.go Refactor organization of scope aware request utils 2021-01-16 13:55:48 -08:00
metrics.go Add Prometheus metrics endpoint 2021-02-15 13:45:26 +00:00
metrics_test.go Add Prometheus metrics endpoint 2021-02-15 13:45:26 +00:00
middleware_suite_test.go Ensure errors in tests are logged to the GinkgoWriter 2021-02-10 19:50:04 +00:00
redirect_to_https.go Make HTTPS Redirect middleware Reverse Proxy aware 2021-01-16 13:55:48 -08:00
redirect_to_https_test.go Make HTTPS Redirect middleware Reverse Proxy aware 2021-01-16 13:55:48 -08:00
scope.go Refactor organization of scope aware request utils 2021-01-16 13:55:48 -08:00
scope_test.go Refactor organization of scope aware request utils 2021-01-16 13:55:48 -08:00
session_utils.go Add Basic Auth session loader middleware 2020-07-19 17:21:42 +01:00
session_utils_test.go Add Basic Auth session loader middleware 2020-07-19 17:21:42 +01:00
stored_session.go Refactor organization of scope aware request utils 2021-01-16 13:55:48 -08:00
stored_session_test.go Refactor organization of scope aware request utils 2021-01-16 13:55:48 -08:00