services:
  jellyfin:
    container_name: jellyfin
    entrypoint:
    - /jellyfin/jellyfin
    environment:
      DEBIAN_FRONTEND: noninteractive
      HEALTHCHECK_URL: http://localhost:8096/health
      JELLYFIN_CACHE_DIR: /cache
      JELLYFIN_CONFIG_DIR: /config/config
      JELLYFIN_DATA_DIR: /config
      JELLYFIN_FFMPEG: /usr/lib/jellyfin-ffmpeg/ffmpeg
      JELLYFIN_LOG_DIR: /config/log
      JELLYFIN_WEB_DIR: /jellyfin/jellyfin-web
      LANG: en_US.UTF-8
      LANGUAGE: en_US:en
      LC_ALL: en_US.UTF-8
      MALLOC_TRIM_THRESHOLD_: '131072'
      NVIDIA_DRIVER_CAPABILITIES: compute,video,utility
      NVIDIA_VISIBLE_DEVICES: all
      PATH: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
      XDG_CACHE_HOME: /cache
    image: jellyfin/jellyfin:latest
    networks:
    - bridge
    ports:
    - 8096:8096/tcp
    restart: unless-stopped
    volumes:
    - jellyfin-config:/config
    - jellyfin-cache:/cache
    - /srv/mergerfs/DataPool/Movies:/media/movies
    - /srv/mergerfs/DataPool/tv_shows:/media/tv_shows
