I will be using Ubuntuserver in this guide. You can select whatever linux distro you prefer.
Download ubuntu server from https://ubuntu.com/download/server. Create a bootable USB drive using rufus or any other software(I prefer ventoy). Plug the usb on your computer, and select the usb drive from the boot menu and install ubuntu server. Follow the steps to install and configure ubuntu, and make sure to check "Install OpenSSH server". Don't install docker during the setup as the snap version is installed.
Once installation finishes you can now reboot and connect to your machine remotely using ssh.
ssh username@server-ip
# username you selected during installation
# Type ip a to find out the ip address of your server. Will be present against device like **enp4s0** prefixed with 192.168.
Create the directories for audiobooks, books, movies, music and tv.
I keep all my media at ~/server/media. If you will be using multiple drives you can look up how to mount drives.
We will be using hardlinks so once the torrents are downloaded they are linked to media directory as well as torrents directory without using double storage space. Read up the trash-guides to have a better understanding.
mkdir ~/server
mkdir ~/server/media # Media directory
mkdir ~/server/torrents # Torrents
# Creating the directories for torrents
cd ~/server/torrents
mkdir audiobooks books incomplete movies music tv
cd ~/server/media
mkdir audiobooks books movies music tv
Jackett is where you define all your torrent indexers. All the *arr apps use the tornzab feed provided by jackett to search torrents.
There is now an *arr app called prowlarr that is meant to be the replacement for jackett. But the flaresolverr(used for auto solving captchas) support was added very recently and doesn't work that well as compared to jackett, so I am still sticking with jackett for meantime. You can instead use prowlarr if none of your indexers use captcha.
Sonarr is a TV show scheduling and searching download program. It will take a list of shows you enjoy, search via Jackett, and add them to the qbittorrent downloads queue.
I personally only use jellyfin because it's completely free. I still have plex installed because overseerr which is used to request movies and tv shows require plex. But that's the only role plex has in my setup.
I will talk about the devices section later on.
For the media volume you only need to provide access to the /data/media directory instead of /data as jellyfin doesn't need to know about the torrents.
As I mentioned in the jellyfin section there is a section in the conmpose file as "devices". It is used for transcoding. If you don't include that section, whenever transcoding happens it will only use CPU. In order to utilise your gpu the devices must be passed on to the container.
The default username is admin and password adminadmin. You can change the user and password by going to Tools → Options → WebUI
Change "Default Save Path" in WebUI section to /data/torrents/ and "Keep incomplete torrents in" to /data/torrents/incomplete/
Create categories by right clicking on sidebar under category. Type category as TV and path as tv. Path needs to be same as the folder you created to store your media. Similarly for movies type Movies as category and path as movies. This will enable to automatically move the media to its correct folder.
Sonarr
Navigate to YOUR_SERVER_IP:8989
Under "Download Clients" add qbittorrent. Enter the host as YOUR_SERVER_IP port as **8080,** and the username and password you used for qbittorrent. In category type TV (or whatever you selected as categoryname(not path) on qbittorent). Test the connection and then save.
Under indexers, for each indexer you added in Jackett
Click on add button
Select Torzab
Copy the tornzab feed for the indexer from jackett
Copy the api key from jackett
Select the categories you want
Test and save
Under general, define the root folder as /data/media/tv
Repeat this process for Radarr, Lidarr and readarr.
Use /data/media/movies as root for Radarr and so on.
The setup for ombi/overseerr is super simple. Just hit the url and follow the on screen instructions.
Bazarr
Navigate to YOUR_SERVER_IP:6767
Go to settings and then sonarr. Enter the host as YOUR_SERVER_IP port as 8989. Copy the api key from sonarr settings→general.
Similarly for radarr, enter the host as YOUR_SERVER_IP port as 7878. Copy the api key from radarr settings→general.
Jellyfin
Go to YOUR_SERVER_IP:8096
Add all the libraries by selecting content type and then giving a name for that library. Select the particular library location from /data/media. Repeat this for movies, tv, music, books and audiobooks.
Go to dashboard→playback, and enable transcoding by selecting as VAAPI and enter the device as /dev/dri/renderD128
Monitor GPU usage while playing content using
sudo intel_gpu_top
Heimdall
Navigate to YOUR_SERVER_IP:8090
Setup all the services you use so you don't need to remember the ports like I showed in the first screenshot.
Updating docker images
With docker compose updates are very easy.
Navigate to the compose file directory ~/server/compose/media-server.
Then docker-compose pull to download the latest images.
And finally docker-compose up -d to use the latest images.
Remove old images by docker system prune -a
What's next
You can setup VPN if torrents are blocked by your ISP/Country. I wanted to keep this guide simple and I don't use VPN for my server, so I have left out the VPN part.
You can read about port forwarding to access your server over the internet.
I recommend to use relevativ paths in the compose files. e.g.
- '/home/${USER}/server/configs/heimdall:/config'
becomes
- './configs/heimdall:/config'
you may want to add ":ro" to configs while you are at it.
also I like to put my service in /srv/ instead of home.
also I don't see anything about https/ssl. I recommend adding a section for letsencrypt.
when services rely on each other, it's a good idea to put them into the same compose file. (on 2nd thought: I am not sure if you already do that? To me it is not clear, if you use 1 big compose file for everything or many small ones. I would prefer to have 1 big one)
you can use "depends_on" to link services together.
you should be consistent with conventions between configurations. And you should remove config-properties that serve no purpose.:
you don't need to specifiy "container_name", when it would be same name as the service
PUID=1000 and PGID=1000 shouldn't be needed, I think.
sometimes you add explicit ":latest" to the version, and sometimes you don't
while you are at it, you may want to consider using an .env file where you could move everything that would differ between different deployment. e.g.
PUID
TZ
exposed ports, maybe
consider using podman instead of docker. The configuration is pretty much identical to docker-syntax. The main difference is, that it doesn't require a deamon with root privileges.
you may want to consider to pin version for the containers.
pro version pinning:
no unexpected changes, when you restart the container (e.g. because you accidentally pulled)
con version pinning:
when you DO want to make an update, you have to spent 2 minutes to go to docker hub to find out which version you want.
I so wish someone would make a cleaned up version that uses something like Podman and better conventions. Honestly, it needs to be a wiki like document that is slowly updated, improved and even varied. Because when I look at these comments I lose faith in implementing the original post.
There is a wiki, at least for dbzer0 users. db0 made a post about it in !div0@lemmy.dbzer0.com. Not sure if other servers will implement it, but would be cool to see!
Honestly, the original is pretty good, bare bones start up. Most of those comments are recommendations, not show stoppers.
Like, the suggestion to use lets encrypt is kinda moot if you don't expose to the outside world. I personally choose to add a VPN (wireguard) and access services from outside of my network through that. OP kinda mentions adding a vpn as well, I do that through gluetun.
I'll also take just about any opportunity I can to point out yams.media which got me started using docker for this and you can see how easy it is from this post to add additional services. You can be a real noob and still get a functional server in like 10 minutes.
I'd encourage you to dig around after you set this up. It's basically setting up a docker compose file, and once you get how docker compose works, it's really, really easy to add your own services. Like if you use usenet, throwing sabnzbd in here is very simple. Or if for some reason you want to run plex and jellyfin at the same time.