Add documentation files
This commit is contained in:
1 parent
fb4cdeb0cd
commit
1d45442fed
7 files changed
+295
No files matched your search
@@ -0,0 +1,41 @@
|
||||
# Reverse Proxy
|
||||
|
||||
This document will explain how to setup a reverse proxy for nginx/freenginx. Contributions for other reverse proxies are welcomed!
|
||||
|
||||
## General prerequisites
|
||||
|
||||
- A domain name pointed at your server e.g. `drawit.yourdomain.com`
|
||||
- Certbot installed for Let's Encrypt certificates (`sudo apt install certbot python3-certbot-nginx`)
|
||||
- Port-forwarding
|
||||
|
||||
## nginx/freenginx
|
||||
|
||||
### Prerequisites
|
||||
|
||||
- nginx/freenginx installed e.g. `sudo apt install nginx`
|
||||
- A domain name pointed at your server e.g. `drawit.yourdomain.com`
|
||||
- Certbot installed for Let's Encrypt certificates (`sudo apt install certbot python3-certbot-nginx`)
|
||||
|
||||
### Install the config file
|
||||
|
||||
Copy the provided config and substitute your domain:
|
||||
|
||||
```bash
|
||||
sudo cp docs/drawit.conf /etc/nginx/sites-available/drawit.conf # OR sudo cp docs/drawit.conf /etc/nginx/conf.d/drawit.conf
|
||||
sudo sed -i 's/your.domain.com/drawit.yourdomain.com/g' /etc/nginx/[sites-available|conf.d]/drawit.conf
|
||||
```
|
||||
|
||||
Enable the site (older nginx versions <1.19):
|
||||
|
||||
```bash
|
||||
sudo ln -s /etc/nginx/sites-available/drawit.conf /etc/nginx/sites-enabled/
|
||||
```
|
||||
|
||||
Test and reload:
|
||||
|
||||
```bash
|
||||
sudo nginx -t # must print "syntax is ok"
|
||||
sudo nginx -s reload # loads changes/new files
|
||||
```
|
||||
|
||||
Visit your site `drawit.yourdomain.com` and see if it loads!
|
||||
Reference in new issue
Block a user