mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-07-16 05:43:54 +03:00
[PR #14052] Enable metrics via an environmental variable, optionally separate Port #13815
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/jellyfin/jellyfin/pull/14052
Author: @cbcoutinho
Created: 5/3/2025
Status: 🔄 Open
Base:
master← Head:master📝 Commits (7)
d251aa5Enable metrics via an environmental variable04dc095Enable /metrics endpoint to be accessible on separate portba6c415Update Emby.Server.Implementations/Configuration/ServerConfigurationManager.cs86e00e9Make it possible to disable metrics using environment variable131f5adMerge remote-tracking branch 'upstream/master'f224ec3Merge remote-tracking branch 'upstream/master'dfda4a6Merge remote-tracking branch 'upstream/master'📊 Changes
6 files changed (+78 additions, -5 deletions)
View changed files
📝
Emby.Server.Implementations/ApplicationHost.cs(+1 -1)📝
Emby.Server.Implementations/Configuration/ServerConfigurationManager.cs(+39 -1)📝
Jellyfin.Server/Program.cs(+20 -1)📝
Jellyfin.Server/ServerSetupApp/SetupServer.cs(+1 -1)📝
Jellyfin.Server/Startup.cs(+10 -1)📝
MediaBrowser.Model/Configuration/ServerConfiguration.cs(+7 -0)📄 Description
Changes
This change builds on #10503, enabling exposing prometheus metrics via an environmental variable rather than updating the system configuration file. This is necessary in containerized environments where the configuration file is not available at startup and requires some workarounds when deploying to Kubernetes. Additionally, users can specify a separate HTTP port to host the
/metricsendpoint. If set to0- the default - the/metricsendpoint will be exposed on the default server port.Users can set the following environmental variables to configure metrics at startup:
JELLYFIN_EnableMetricsJELLYFIN_MetricsListenPortAs requested in the original PR, the changes have been moved to
ServerConfigurationManager.Issues
Fixes #6247
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.