# documentation: https://docs.linuxserver.io/images/docker-plex/
# slogan: Plex organizes video, music and photos from personal media libraries and streams them to smart TVs, streaming boxes and mobile devices.
# category: media
# tags: media, server, movies, tv, music
# logo: svgs/plex.svg
# port: 32400

services:
  plex:
    image: lscr.io/linuxserver/plex:latest
    environment:
      - SERVICE_URL_PLEX_32400
      - _APP_URL=$SERVICE_URL_PLEX
      - PUID=1000
      - PGID=1000
      - TZ=${TZ:-America/Toronto}
      - PLEX_CLAIM=${PLEX_CLAIM}
    #devices:
    #  - "/dev/dri:/dev/dri"
    volumes:
      - plex-config:/config
      - plex-tv:/tv
      - plex-movies:/movies
    healthcheck:
      test: ["CMD", "curl", "-f", "http://localhost:32400/identity"]
      interval: 2s
      timeout: 10s
      retries: 15
