Self-host media stack (Jellyfin+Radarr+Sonarr+Prowlarr+qBittorrent)

Navratan Lal Gupta
Linux Shots
Published in
6 min readAug 6, 2022

Disclaimer: Neither the author of this article nor the publication nor the developers of codes used in this article condone or encourage downloading, sharing, seeding, or peering copyright material. International laws prohibit such activities which are illegal. This article serves educational purposes only.

Self-hosting complete media stack in your home server gives you privacy and complete control over your data. This media stack consist of collection of tools which serves their specific purpose.

Jellyfin — Jellyfin is Free and Open Source software which is used to manage and stream media.

Radarr — Radarr is Free and Open Source software which is used to automatically download movies via Usenet and BitTorrent.

Sonarr —Sonarr is Free and Open Source software which is used to automatically download TV Shows via Usenet and BitTorrent.

Prowlarr— Prowlarr is a proxy server used for parsing results requested by any application from tracker sites. It is also a Free and Open Source.

qBittorrent— qBittorrent is a Free and Open Source torrent client used for downloading, seeding and peering on torrent network.

THIS DOCUMENT IS OUTDATED.

PLEASE FOLLOW README.md from my Github repo to get latest document. Here is the link.

But hey, Don’t forget to clap on this document too.

Now that we have known the components of stack and their purpose. Lets start with deployment and configuration.

Contents:

  1. Prerequisites
  2. Deploy media stack
  3. Configure Jackett
  4. Configure Transmission
  5. Configure Radarr
  6. Configure Sonarr
  7. Configure Jellyfin
  8. Test media stack
  9. How this works ?

Prerequisites:

  1. Linux server on ARM64 or AMD64 CPU architecture
  2. Docker 20.10.17+
  3. Docker-compose v2.6.1+
  4. Minimum 6GB RAM and 4 CPUs
  5. Enough storage to store the movies and TV Shows

Deploy media stack:

  1. Clone github repo.
git clone https://github.com/navilg/media-stack.git
cd media-stack

2. Change Username and Password of transmission in docker-compose.

In docker-compose.yml file, Under services.transmission.environment . Update values of USER and PASS environment variable to change username and password.

3. Create docker network

docker network create mynetwork

4. Deploy applications

## There are two stacks available. 
## stack-1 contains Jellyfin, Radarr, Sonarr, Jackett and Transmission.
## stack-2 contains Jellyfin, Radarr, Sonarr, Prowlarr, qBitTorrent and VPN
## This article mainly focus on deploying and configuring stack-1. To deploy and configure stack-2, visit https://github.com/navilg/media-stackdocker-compose --profile stack-1 up -d
docker ps

Configure Jackett:

  1. Open Jackett in browser on http://ip-address-or-domain:9117. Make sure port 9117 is open in firewall/security group.
  2. Scroll to down and set admin password.

3. Add indexers.

Click on Add Indexer button → Search for your torrent indexers → Select them and Add selected.

Configure Transmission:

  1. Open Transmission in browser using ip address or domain of server ip-address-or-domain:9091 and check if UI is accessible. Make sure firewall rule allows port.

2. In backend, Get inside transmission container and run below commands.

docker exec -it transmission bash # Get inside transmission container
mkdir /downloads/movies /downloads/tvshows
chown 1000:1000 /downloads/movies /downloads/tvshows

Configure Radarr:

  1. Open Radarr on browser using ip address or domain of your server ip-address-or-domain:7878. Make sure firewall/security group allows port 7878.
  2. Set username and password. Settings --> General --> Security --> Authentication --> Choose Forms --> Set Username and Password--> Save changes.

3. Add download client. Setting --> Download clients --> Add download clients (+) --> Choose Transmission from options --> Add name, Host (transmission), Port (9091), Username and password of transmission --> Test --> If test is successful, save.

4. Add indexer. Settings --> Indexers --> Add Indexer (+) --> Choose Rarbg --> Test --> If test is successful, Save.

You can also add Indexers added in Jackett. Read the instruction in Jackett home page.

5. Setup media management. Settings --> Media Management --> Show Advanced --> Check Mark 'Rename Movies' --> Check mark 'Delete Empty Folders' --> Check mark 'Unmonitor Delete movies' --> Add /data/downloads/movies in Root folder --> Save changes.

Configure Sonarr:

  1. Open Sonarr on browser using ip address or domain name of server ip-address-or-domain:8989. Make sure firewall rule allows this port.

All settings and configuration will be same as Radarr with minimal self-understood differences. While configuring, Keep in mind that Radarr is to manage and download TV shows and not a movie.

Configure Jellyfin:

  1. Open Jellyfin in browser using ip address or domain name of server ip-address-or-domain:8096. Make sure firewall rule allows this port.
  2. Setup the Jellyfin as per Jellyfin’s first time setup guide tour. Choose preffered language --> Set admin username and password --> Setup media library (You can skip this as of now, See next step for process) --> Next, Next and Finish.
  3. Setup media library. Login as admin user --> CLick 3 bars on top-left --> Dashboard under Administration --> Libraries --> Add Media Libraries --> Content Type = Movies --> Add Folders (+) --> Choose /data/movies folder --> OK --> Add another media library for TV Shows and select /data/tvshows folder.
  4. Create new non-admin user. Dashboard --> Users --> Add user (+) --> Add username and password --> Choose libraries to give access --> Save.
  5. You can download jellyfin client for mobile or desktop for streaming media. Or you can also use browser.

Test media stack:

  1. Open Radarr in browser.
  2. Search for your movie (Its advised to download only non-copyright movies available in public domain) → Select Quality profile → Check mark ‘start search for missing movie’ → Add Movie.
  3. Click on Movies →Select the added movie → Click on Search Movie.
  4. It should search for the movie and start downloading movies.
  5. You can open Transmission in browser to see the queue. This can also be viewed in Radarr under Activity section.
  6. Once Download is successful, Login to Jellyfin and the movie should be available to watch/stream.
  7. Test for TV shows in Sonarr in same way.

How this works ?

  • When we search for a movie or TV Shows in Radarr and Sonarr, It looks for them in The Movie Database (TMDb).
  • After we add a movie to Radarr, Radarr sends a query/request to Jackett to look for the movies in Indexers.
  • Once movie with all the requirements met is found in any of setup torrent indexers, Radarr sends the magnet link to Transmission to download/leech the movie from torrent network/peers/seeders.
  • Once Transmission downloads the movie, It creates a hard link in root folder of Radarr.
  • During scheduled periodic scan of libraries, Jellyfin finds the movie in root folder of Radarr and adds it to its library for streaming.
  • Same way goes with Sonarr for TV Shows.

Here you have deployed and setup complete media stack to manage and stream media. For details about each application, Please visit their official websites added in hyperlinks in above tool names.

You may also put all of them behind Nginx and apply SSL to it. To know the Nginx reverse proxy configuration, Read thishttps://github.com/navilg/media-stack/blob/main/README.md.

Thanks

Navratan Lal Gupta

Linux Shots

--

--

Navratan Lal Gupta
Linux Shots

I talk about Linux, DevOps, Kubernetes, Docker, opensource and Cloud technology. Don't forget to follow me and my publication linuxshots.