Plex Media Server is a software application that allows you to organize and stream your collection of movies, TV shows, music, and photos, from a central location. Think of it like having your own personal Netflix or Spotify server that you can access from various devices. It’s a great tool for anyone who wants to streamline their media consumption and take control of their entertainment experience
Optional. Connect an usb hdd
Create a folder to mount the disk: sudo mkdir -p /mnt/hdd
Get the sdX of your drive: lsblk
For example, our hdd has the label sd1
Get the uuid of the hdd: blkid /dev/sdb1
Then, edit fstab: sudo nano /etc/fstab
Add to the file uuid and options:
UUID={{OBTAINEDUUID}} /mnt/hdd ext4 auto,nofail,noatime,rw,user,x-systemd.device-timeout=10s 0 0
Mounting An External Drive On Ubuntu Server – Ken Favors . com
Create a plex account
Install Plex with docker
First of all install docker ce into your server. Remember to run the post-actions to get it working properly.
Get a plex token
Once docker is installed, just execute the following script into you server:
docker run \
-d \
--name plex \
--network=host \
-e TZ="Europe/Madrid" \
-e PLEX_CLAIM="{{PLEXTOKEN}}" \
-e PLEX_UID=1000 \
-e PLEX_UID=1000 \
-v /var/lib/plexmediaserver:/config \
-v {{configDir}}/transcode:/transcode \
-v {{configDir}}/media:/data \
-v /mnt/hdd/movies:/movies \
-v /mnt/hdd/music:/music \
--restart=always \
--pull always \
plexinc/pms-docker:1.32.8.7639-fb6452ebf
Access to plex
After the docker is fully up (you can check it with docker ps) you should be able to access to http://{{YOURSERVERIP}}:32400
This will get you to your plex server to start using it.