mirror of
https://github.com/Sonarr/Sonarr.git
synced 2024-11-21 10:12:35 +01:00
Page:
Reverse Proxy
Pages
Anime naming scheme
AppData Directory
Asking for Help
Backup and Restore
Cannot install update because startup folder is not writable by the user
Command Line Options
Completed Download Handling
Configuration
Custom Lists
Custom Post Processing Scripts
Delay Profiles
Disable Authentication
Downloads and Importing
FAQ
Failed Download Handling
Forgot my Password
Health Checks
Home
Implementing a Torznab indexer
Indexer Integration
Indexer Seed Ratio
Installation (v3 beta) Fedora 31
Installation CentOS 7
Installation CentOS 8 V3 Beta
Installation CentOS 8
Language Profile
Log Files
Logging and Log Files
Manual Episode Search Trace Log
Manual Episode Search XML Output
Manually Triggering Imports
Master Migration
Monitoring Series and Episodes
Problematic Shows
Profiles
PushOver
Quality Profile
RSS Sync
Recovering from a Failed Update
Release Branches
Reverse Proxy
Reverse symlink script for Connect
SSL
Searches Indexers and Trackers
Sonarr notifications in Slack using curl
Sorting and Renaming
Specifying install user on Deb Ubu
Supported DownloadClients
Supported Indexers
Supported Notifications
Tips and Tricks
Twitter Notifications
Updating
Webhook Schema
Webhook
10
Reverse Proxy
bakerboy448 edited this page 2022-05-20 09:47:45 -05:00
Table of Contents
Note: this is the Legacy v2 Wiki. The new V3 Wiki can be found at the Servarr Wiki. Sonarr v2 is end of life and not supported.
The nginx details can be found on the Installation page in the new wiki
Linux / OSX
Prerequisites
- Install Nginx or Apache
- Optional: have an SSL certificate. A free one can be obtained using "Let's Encrypt"
Nginx Conf
Nginx is by far, easier to setup a reverse proxy. Depending on your distro, the location of the Nginx conf or access log may be different than what's shown below. Please use these as a guide.
HTTP (non-SSL)
Create a new config here: /etc/nginx/sites-enabled/sonarr.your-domain.xyz
With the following contents:
server {
listen 80;
server_name sonarr.your-domain.xyz;
location / {
proxy_pass http://127.0.0.1:8989;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_redirect off;
proxy_buffering off;
}
access_log /var/log/nginx/sonarr.your-domain.xyz;
}
Reload Nginx: nginx -s reload
HTTPS (with SSL certificate)
Create a new config here: /etc/nginx/sites-enabled/sonarr.your-domain.xyz
With the following contents:
server {
listen 80;
server_name sonarr.you-domain.xyz;
return 301 https://$host$request_uri;
}
server {
listen 443 ssl;
server_name sonarr.you-domain.xyz;
add_header Strict-Transport-Security "max-age=31536000; includeSubDomains" always;
ssl_certificate /path/to/your/ssl-cert;
ssl_certificate_key /path/to/your/ssl-key;
ssl_session_cache shared:SSL:1m;
ssl_session_timeout 5m;
ssl_prefer_server_ciphers on;
ssl_protocols TLSv1.1 TLSv1.2;
ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:DHE-RSA-AES128-GCM-SHA256:DHE-DSS-AES128-GCM-SHA256:kEDH+AESGCM:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:DHE-RSA-AES128-SHA256:DHE-RSA-AES128-SHA:DHE-DSS-AES128-SHA256:DHE-RSA-AES256-SHA256:DHE-DSS-AES256-SHA:DHE-RSA-AES256-SHA:AES128-GCM-SHA256:AES256-GCM-SHA384:AES128-SHA256:AES256-SHA256:AES128-SHA:AES256-SHA:AES:CAMELLIA:DES-CBC3-SHA:!aNULL:!eNULL:!EXPORT:!DES:!RC4:!MD5:!PSK:!aECDH:!EDH-DSS-DES-CBC3-SHA:!EDH-RSA-DES-CBC3-SHA:!KRB5-DES-CBC3-SHA;
access_log /var/log/nginx/sonarr.you-domain.xyz.log;
location / {
proxy_pass http://127.0.0.1:8989;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_redirect off;
proxy_buffering off;
}
}
Reload Nginx: nginx -s reload
Windows
Variant 1: Setting the URL base in the UI
- Go to Settings -> General
- Set URL Base to desired path
- Save settings
- Restart (Restart as administrator on Windows)
- Donate <3
Variant 2: Editing the configuration file
- Open file ~/.config/NzbDrone/config.xml
- Add entry your/desired/path
NB Note that UrlBase doesn't start with a slash otherwise it wont work!
Getting Started
Troubleshooting
- Asking for Help
- Logging and Log Files
- AppData Directory
- Searches Indexers and Trackers
- Downloads and Importing
- Recovering from a Failed Update
Additional Configuration
More Information
- Completed Download Handling
- Failed Download Handling
- Indexer Integration
- Backup and Restore
- PushOver
- Sorting and Renaming
- Anime naming scheme
- Monitoring Series and Episodes
- RSS Sync
- Indexer Seed Ratio
Development