aboutsummaryrefslogtreecommitdiffstats

Plex Server Setup

This repository contains scripts and configuration for setting up a Plex Media Server on Ubuntu. I run this on a Raspberry Pi 4B.

Installation

1. Copy the Files over to Your Server

scp compose.yaml .env.example setup-docker.sh setup-drive.sh <username>@<server>:/home/<username>/

2. SSH into Your Server

ssh <username>@<server>

3. Configure Your Environment

Copy the Example Env File

cp .env.example .env

Fill in PLEX_CLAIM with Your Plex Claim Token

Get a claim token from Plex

4. Run the Installation Scripts

Install Docker

sudo ./setup-docker.sh

Set up External Drive

If you’re using an external hard drive for your media, set up the fstab entry for it:

sudo ./setup-drive.sh

The defaults use my hard drive assumptions. To use different configuration, pass the overrides before the command:

FSTAB_UUID=your-uuid FSTAB_MOUNT_POINT=/mnt/data FSTAB_FS_TYPE=ext4 sudo -E ./setup-drive.sh

After you’ve added the fstab entry, mount the drive:

sudo mount -a

5. Start Plex

docker compose up --detach

Tailscale Setup

If you want to have access to your server outside of your home network, you can setup tailscale to do so.

scp setup-tailscale.sh <username>@<server>:/home/<username>/
sudo ./setup-tailscale.sh

The script will print a URL to authenticate in a browser.