mirror of
https://github.com/cyclotruc/gitingest.git
synced 2026-04-28 08:09:31 +00:00
fix: enable metrics if env var is defined instead of being "True" (#407)
This commit is contained in:
parent
1016f6ecb3
commit
fa2e192c05
1 changed files with 1 additions and 1 deletions
|
|
@ -29,7 +29,7 @@ app.state.limiter = limiter
|
|||
app.add_exception_handler(RateLimitExceeded, rate_limit_exception_handler)
|
||||
|
||||
# Start metrics server in a separate thread if enabled
|
||||
if os.getenv("GITINGEST_METRICS_ENABLED", "false").lower() == "true":
|
||||
if os.getenv("GITINGEST_METRICS_ENABLED") is not None:
|
||||
metrics_host = os.getenv("GITINGEST_METRICS_HOST", "127.0.0.1")
|
||||
metrics_port = int(os.getenv("GITINGEST_METRICS_PORT", "9090"))
|
||||
metrics_thread = threading.Thread(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue