[PR #1811] [MERGED] Configure Kestrel listener to use configured IPs #8899

Closed
opened 2026-02-07 05:52:23 +03:00 by OVERLORD · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/jellyfin/jellyfin/pull/1811
Author: @joshuaboniface
Created: 9/29/2019
Status: Merged
Merged: 9/30/2019
Merged by: @joshuaboniface

Base: masterHead: fix-listen


📝 Commits (2)

  • cabb9ae Configure Kestrel listener to use configured IPs
  • 3871926 Handle Kestrel startup failures with a nice error

📊 Changes

1 file changed (+35 additions, -4 deletions)

View changed files

📝 Emby.Server.Implementations/ApplicationHost.cs (+35 -4)

📄 Description

Changes
Our Kestrel configuration used ListenAnyIP, probably a testing/initial configuration holdover. This resulted in Kestrel always binding to a wildcard instead of the configured addresses.

This PR implements a per-IP listener, based on https://docs.microsoft.com/en-us/aspnet/core/fundamentals/servers/kestrel?view=aspnetcore-3.0#bind-to-a-tcp-socket. It will loop through all configured IPs and listen on all of them, or listen on all interfaces as was the default if no explicit IPs are are specified.

Explicitly works with 0.0.0.0 as well to force IPv4-only wildcard binding.

Issues
Fixes #1810


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/jellyfin/jellyfin/pull/1811 **Author:** [@joshuaboniface](https://github.com/joshuaboniface) **Created:** 9/29/2019 **Status:** ✅ Merged **Merged:** 9/30/2019 **Merged by:** [@joshuaboniface](https://github.com/joshuaboniface) **Base:** `master` ← **Head:** `fix-listen` --- ### 📝 Commits (2) - [`cabb9ae`](https://github.com/jellyfin/jellyfin/commit/cabb9aed3142773ab3bec4627b2aec3dc470f02e) Configure Kestrel listener to use configured IPs - [`3871926`](https://github.com/jellyfin/jellyfin/commit/387192610f5aca62e691dfe2dfed92a5889c6cd7) Handle Kestrel startup failures with a nice error ### 📊 Changes **1 file changed** (+35 additions, -4 deletions) <details> <summary>View changed files</summary> 📝 `Emby.Server.Implementations/ApplicationHost.cs` (+35 -4) </details> ### 📄 Description **Changes** Our Kestrel configuration used `ListenAnyIP`, probably a testing/initial configuration holdover. This resulted in Kestrel always binding to a wildcard instead of the configured addresses. This PR implements a per-IP listener, based on https://docs.microsoft.com/en-us/aspnet/core/fundamentals/servers/kestrel?view=aspnetcore-3.0#bind-to-a-tcp-socket. It will loop through all configured IPs and listen on all of them, or listen on all interfaces as was the default if no explicit IPs are are specified. Explicitly works with `0.0.0.0` as well to force IPv4-only wildcard binding. **Issues** Fixes #1810 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
OVERLORD added the pull-request label 2026-02-07 05:52:23 +03:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/jellyfin#8899