Yourls

Yourls is a URL shortener.

Configure Yourls

Run this on the Raspberry Pi
pi make yourls config

Follow the prompts to configure the domain name and admin user authentication.

(stdout)
YOURLS_TRAEFIK_HOST: Enter the YOURLS domain name (e.g., yourls.example.com)

: yourls.pi.example.com

? Do you want to enable sentry authorization in front of this app (effectively making the entire site private)?
> No
  Yes, with HTTP Basic Authentication
  Yes, with Oauth2
  Yes, with Mutual TLS (mTLS)

YOURLS_USER: Enter the admin username for your YOURLS instance

: admin

YOURLS_PASS: Enter the password for 'admin'

: 528e0e36fc170

Choose your own a secure passphrase!

Run this on the Raspberry Pi
pi make yourls install wait

Wait for the services to start and report themselves as healthy:

(stdout)
Waiting until all services are started and become healthy ...
All services healthy.

Add a new route on the sentry (droplet)

Run this on the Raspberry Pi
sentry make traefik config
(stdout)
? Traefik:
> Config
  Install (make install)
  Admin
  Exit (ESC)

? Traefik Configuration:
^ Entrypoints (including dashboard)
  TLS certificates and authorities
  Middleware (including sentry auth)
> Advanced Routing (Layer 7 / Layer 4 / WireGuard)
  Error page template
  Logging level
  Access logs

? Traefik routes
> Configure layer 7 TLS proxy
  Configure layer 4 TCP/UDP proxy
  Configure wireguard VPN

? Layer 7 TLS Proxy:
  List layer 7 ingress routes
> Add new layer 7 ingress route
  Remove layer 7 ingress routes
  Disable layer 7 TLS Proxy

Enter the public domain (SNI) for the route:

: yourls.pi.example.com

Enter the destination IP address to forward to:

: 10.13.16.2

Enter the destination TCP port to forward to:

: 443

> Do you want to enable Proxy Protocol for this route? Yes

## Layer 7 TLS Proxy is ENABLED.
## Configured Layer 7 Routes:
Entrypoint              Destination_address  Destination_port  Proxy_protocol
----------              -------------------  ----------------  --------------
yourls.pi.example.com  10.13.16.2           443               2

Press ESC three times to go back to the main menu, and re-install Traefik:

(stdout)
? Traefik:
  Config
> Install (make install)
  Admin
  Exit (ESC)

After installation, press ESC to quit the config tool.

Finish

Immediately secure the admin account

You should immediately open the URL in your web browser: https://yourls.pi.example.com/admin and complete the initial configuration to finsh installation.

There is no page at the root URL (Forbidden.) To administer the site, you must go to the page https://yourls.pi.example.com/admin.