Created
January 20, 2018 23:53
-
-
Save phillijw/8a3239be74847ab166d2585231edff94 to your computer and use it in GitHub Desktop.
Setting up plex in a docker container
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Goal: Set up Plex for my LAN inside a docker container. I am not using or relying on the plex.tv website at all. This | |
is all local to my network. Plex updates happen through the web interface. I'm not sure how I'm going to handle | |
the docker image updates yet or if I will even worry about it. | |
First, set up a ramdisk (type=tmpfs; I used 4GB but smaller is fine probably) to use for transcoding. This allows plex to | |
transcode files without reading and writing constantly from your SSD or other disk drive. This lets it do it all in | |
memory instead. I mounted this at /mnt/ramdisk and then set it up in my fstab so it persists through reboots. | |
Second, make sure you have docker installed ya big dummy. | |
Third, run this command... modify it to your needs: | |
docker run \ | |
-d \ | |
--name plex \ | |
--network=host \ | |
-p 32400:32400/tcp \ | |
-e TZ="America/Chicago" \ | |
-v /home/phillijw/docker/plex/config:/config \ | |
-v /mnt/ramdisk/docker/plex/transcode:/transcode \ | |
-v /media/phillijw/KingKong/tv:/data/tv \ | |
-v /media/phillijw/KingKong/movies:/data/movies \ | |
--restart always \ | |
plexinc/pms-docker | |
Updated to be a little better... a compose file might be a better idea but this seems to work and it keeps plex updated I think
docker run \
-d \
--name plex \
-p 32400:32400/tcp \
-p 3005:3005/tcp \
-p 8324:8324/tcp \
-p 32469:32469/tcp \
-p 1900:1900/udp \
-p 32410:32410/udp \
-p 32412:32412/udp \
-p 32413:32413/udp \
-p 32414:32414/udp \
-e TZ="America/Chicago" \
-e ADVERTISE_IP="http://192.168.1.137:32400/" \
-e PUID=1000 \
-e PGID=1000 \
-v /home/phillijw/docker/plex/config:/config \
-v /mnt/ramdisk/docker/plex/transcode:/transcode \
-v /media/KingKong/tv:/data/tv \
-v /media/KingKong/movies:/data/movies \
--restart unless-stopped \
plexinc/pms-docker:latest
saltystew uses this compose file if I feel like converting: https://gist.github.com/Saltystew/40072336b65dedcd6389057834c39478
docker run \
-d \
--name plex \
-p 32400:32400/tcp \
-p 3005:3005/tcp \
-p 8324:8324/tcp \
-p 32469:32469/tcp \
-p 1900:1900/udp \
-p 32410:32410/udp \
-p 32412:32412/udp \
-p 32413:32413/udp \
-p 32414:32414/udp \
-e TZ="America/Chicago" \
-e ADVERTISE_IP="http://192.168.1.137:32400/" \
-e PUID=1000 \
-e PGID=1000 \
-e VERSION=latest \
-v /var/lib/docker/volumes/plex/config:/config \
-v /mnt/ramdisk/docker/plex/transcode:/transcode \
-v /media/kingkong/tv:/data/tv \
-v /media/kingkong/movies:/data/movies \
--restart unless-stopped \
linuxserver/plex
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Might want to use the plexinc/pms-docker:latest tag and then create new containers periodically to upgrade to latest version (config folder should maintain settings I hope)