Search…
RCL Reverse Proxy
Reverse Proxy details
We have implemented a reverse proxy server in order to securely serve local services over the internet.

Install

In the unforunate event we need to reinstall the reverse proxy server, here are the steps to replicate it:
  1. 1.
    Install Raspberry Pi OS Lite (32bit) to a Sandisk Endurance Pro SD card (longer sd card life)
  2. 2.
    log in via ssh
  3. 3.
    run sudo raspi-config
    1. 1.
      change the default pi password
    2. 2.
      expand the filesystem
  4. 4.
    run sudo apt update && apt upgrade
  5. 5.
    run curl -sSL https://get.docker.com | sh
  6. 6.
    run sudo usermod -aG docker pi
  7. 7.
    run sudo usermod -aG docker ${USER} to set the permissions to the current user
  8. 8.
    run sudo apt-get install -y libffi-dev libssl-dev
  9. 9.
    run sudo apt-get install -y python3 python3-pip
  10. 10.
    run sudo systemctl enable docker to allow docker to start containers on boot
  11. 11.
    run nano docker-compose.yml and paste the following in:
1
version: '3'
2
services:
3
app:
4
image: 'jc21/nginx-proxy-manager:latest'
5
restart: unless-stopped
6
ports:
7
- '80:80'
8
- '81:81'
9
- '443:443'
10
volumes:
11
- ./data:/data
12
- ./letsencrypt:/etc/letsencrypt
Copied!
12. follow quick start instructions here: https://nginxproxymanager.com/guide/#quick-setup 13. run sudo nano etc/systemd/system/nginx-reverse-proxy-app.service
paste the following in and save with ctrl+x -> y :
1
# /etc/systemd/system/nginx-reverse-proxy-app.service
2
3
[Unit]
4
Description=Docker Compose Application Service
5
Requires=docker.service
6
After=docker.service
7
8
[Service]
9
WorkingDirectory=/home/pi
10
ExecStart=/usr/local/bin/docker-compose up
11
ExecStop=/usr/local/bin/docker-compose down
12
TimeoutStartSec=0
13
Restart=on-failure
14
StartLimitIntervalSec=60
15
StartLimitBurst=3
16
17
[Install]
18
WantedBy=multi-user.target
Copied!
14. run systemctl enable nginx-reverse-proxy-app.service to enable it to run on boot
Last modified 1mo ago
Copy link
Contents
Install