Server Version#: 1.18.6.2368
Player Version#: ?
Hi, I’ve been running the official Plex docker container on Ubuntu server for a while now.
Recently I’ve purchased my own domain and I’d like to have Plex be available at plex.domain.com.
I have succeeded to do so, but the performance has just been horrible (where it was fine before). My upload speed is about 50mbps and even loading the library remotely takes minutes.
to give you an indication of how long this really takes here’s a line of the Traefik access log:
192.168.0.1 - - [08/Feb/2020:10:55:56 +0000] “GET /web/chunk-2-a38d252c0e1339adc3b1-plex-4.20.2-57fe380.css HTTP/2.0” 200 978226 “-” “-” 30 “plex@docker” “http://172.26.0.2:32400” 14258ms
Nearly 15 seconds just to get a small css file from Plex, starting to stream doesn’t even work.
Loading certain javascript files takes over a minute!
Now I’m note sure what’s causing this, I’ve looked into many logs and did quite some research but I haven’t found anything that has been able to improve my performance. I was originally inspired by this post.
I have already messed around with secure connections required/optional but so far it hasn’t made a difference.
If anyone would like to help I’d really appreciate it.
Below is are a few parts of my docker compose to indicate how I’ve set this up.
Compose file
version: “3.7”
services:
dockerproxy:
container_name: dockerproxy
restart: always
image: tecnativa/docker-socket-proxy
volumes:
- /var/run/docker.sock:/var/run/docker.sock:z
environment:
CONTAINERS: 1
networks:
- web
traefik:
container_name: traefik
restart: always
image: traefik
depends_on:
- dockerproxy
security_opt:
- no-new-privileges:true
networks:
- web
ports:
- target: 80
published: 80
protocol: tcp
mode: host
- target: 443
published: 443
protocol: tcp
mode: host
- target: 8080
published: 8080
protocol: tcp
mode: host
volumes:
- /etc/localtime:/etc/localtime:ro
- {USERDIR}/docker/traefik/letsencrypt:/letsencrypt
- {USERDIR}/docker/traefik/logs:/var/log/docker
command:
- “–log=true”
- “–log.level=INFO”
- “–accessLog=true”
- “–accessLog.filePath=/var/log/docker/traefik.log”
- “–accessLog.bufferingSize=1000”
- “–global.sendAnonymousUsage=false”
- “–providers.docker.exposedByDefault=false”
- “–providers.docker.network=docker_web”
- “–providers.docker.swarmMode=false”
- “–providers.docker.endpoint=tcp://dockerproxy:2375”
- “–api.insecure=true”
- “–providers.docker=true”
- “–providers.docker.exposedbydefault=false”
- “–entrypoints.web.address=:80”
- “–entrypoints.websecure.address=:443”
- “–certificatesresolvers.myhttpchallenge.acme.httpchallenge=true”
- “–certificatesresolvers.myhttpchallenge.acme.httpchallenge.entrypoint=web”
- “--certificatesresolvers.myhttpchallenge.acme.email=postmaster@domain.com”
- “–certificatesresolvers.myhttpchallenge.acme.storage=/letsencrypt/acme.json”
labels:
- “traefik.http.middlewares.traefik-headers.headers.sslredirect=true”
- “traefik.http.middlewares.traefik-headers.headers.sslforcehost=true”
- “traefik.http.middlewares.traefik-headers.headers.sslproxyheaders.X-Forwarded-Proto=https”
- “traefik.http.middlewares.traefik-headers.headers.framedeny=true”
- “traefik.http.middlewares.traefik-headers.headers.contenttypenosniff=true”
- “traefik.http.middlewares.traefik-headers.headers.browserxssfilter=true”
- “traefik.http.middlewares.traefik-headers.headers.referrerpolicy=same-origin”
plex:
container_name: plex
restart: always
image: plexinc/pms-docker:plexpass
volumes:
- {USERDIR}/docker/plexms:/config
- {USERDIR}/docker/plexms/plex_tmp_transcode:/transcode
- /data/Media:/Media:ro
- {USERDIR}/docker/shared:/shared
ports:
- 32400:32400/tcp
- 3005:3005/tcp
- 8324:8324/tcp
- 32469:32469/tcp
- 1900:1900/udp
- 32410:32410/udp
- 32412:32412/udp
- 32413:32413/udp
- 32414:32414/udp
environment:
- TZ={TZ}
- HOSTNAME=plex.domain.com
- PLEX_CLAIM=claim-xxxxxxxxxxxx
- PLEX_UID={PUID}
- PLEX_GID={PGID}
- ADVERTISE_IP=https://plex.domain.com/
networks:
- web
labels:
- “traefik.enable=true”
- “traefik.http.routers.plex.rule=Host(plex.domain.com)”
- “traefik.http.routers.plex.entrypoints=websecure”
- “traefik.http.routers.plex.tls.certresolver=myhttpchallenge”
- “traefik.http.services.plex.loadbalancer.server.port=32400”
networks:
web:
external: false
internal:
external: false`
Again any help or suggestions are greatly appreciated.