Jellyfin network auto discovery

im running my containers on host vs an app or tn yaml config and i cant get auto discovery working.

if i manually check it seems to return fine :thinking:

$ socat - udp-sendto:jellyfin.example.com:7359,broadcast <<< ‘Who is JellyfinServer?’
{“Address”:“https://jellyfin.example.com”,“Id”:“17be1319e5ed41c0b95361ed7b979f55”,“Name”:“exampleServerName”,“EndpointAddress”:null}

compose:

services:
  jellyfin:
    image: jellyfin/jellyfin
    container_name: jellyfin
    restart: unless-stopped
    user: 1000:1000
    environment:
      - JELLYFIN_PublishedServerUrl=https://jellyfin.example.com
    group_add:
      - 107
    ports:
      - 8096:8096
      - 7359:7359/udp
...

my clients trying to auto discover are the jf android app and google tv app. its probably something simple that im just missing.

The socat test working from the host but clients not finding the server sounds like the UDP broadcast on port 7359 is not reaching the container. Check your compose — do you have network_mode: host set? If not, Docker bridge networking will swallow the UDP broadcast before it hits Jellyfin.

Alternatively if you want to keep bridge networking just publish the discovery port explicitly with 7359:7359/udp in your ports section.

Also worth checking that the client device is on the same subnet as the TrueNAS host since UDP broadcast does not cross subnets.

sorry, that socat test was run from my laptop on the same network. i dont think network_mode: host is possible on the jellyfin service as all my services are on the same docker network and run through a wireguard/reverse proxy.

are you referring to the ports section in compose as i already have it or in truenas networking? all of my clients are on the same subnet.

Ah right, if everything is behind a WireGuard tunnel and reverse proxy on a shared Docker network then UDP broadcast auto-discovery basically cannot work — broadcasts do not cross the tunnel or proxy boundary. Your clients would need to be pointed at the Jellyfin URL directly rather than relying on discovery. In the Jellyfin client apps you can just enter the server address manually (https://jellyfin.example.com) and skip the auto-discovery step entirely.

If you really want discovery to work for LAN clients, you would need a lightweight UDP responder running on the host network (outside Docker) that answers on port 7359 and points clients to the reverse proxy URL. But honestly manual server entry is the easier path here.

1 Like

just to be clear on my docker network setup, leaving out the irrelevant config parts:

services:
  wireguard:
    image: lscr.io/linuxserver/wireguard:latest
    container_name: wireguard
    cap_add:
      - NET_ADMIN
      - SYS_MODULE #optional
    environment:
      - PUID=1000
      - PGID=1000
    ports:
      - 51820:51820/udp
      - 80:80
      - 443:443
    sysctls:
      - net.ipv4.conf.all.src_valid_mark=1
    restart: unless-stopped
    networks:
      - swag
  swag:
    image: lscr.io/linuxserver/swag
    container_name: swag
    network_mode: service:wireguard
    restart: unless-stopped
    depends_on:
      - wireguard

networks:
  swag:
    name: swag
services:
  jellyfin:
    image: jellyfin/jellyfin
    container_name: jellyfin
    restart: unless-stopped
    user: 1000:1000
    environment:
     - JELLYFIN_PublishedServerUrl=https://jellyfin.example.com
    ports:
      - 8096:8096
      - 7359:7359/udp

    networks:
      - swag

networks:
  swag:
    name: swag

its possible im misremembering but auto-discovery worked when i was running on bare metal ubuntu server with this same docker setup.