lighttp - redirect to other server in the same network

Have some feedback, questions, suggestions, or just fancy a chat? Pop it in here.
Post Reply
gtludwig
Posts: 18
Joined: Tue Nov 17, 2020 11:28 am

lighttp - redirect to other server in the same network

Post by gtludwig »

Hi,

I've two dietpi running in my network: 253 and 254.

On 254, I have set an SSL cert using dietpi-letsencrypt and have set port-forwarding in my ISP box and router. So, I land at the lighttp welcome page if I access via the no-ip address.

I would like to access https://<my-no-ip>/foundry-vtt and have it redirected to 253 port 30000.

I have created the file /etc/lighttpd/conf-available/98-network_foundry-vtt.conf and created the symlink in /etc/lighttpd/conf-enabled and restarted lighttpd with # service lighttpd restart.

/etc/lighttpd/conf-available/98-network_foundry-vtt.conf reads as:

Code: Select all

$HTTP["url"] =~ "^/foundry-vtt" {
     url.redirect = ("^/foundry-vtt" => "http://192.168.50.253:30000")
 }
Am I million miles away from the solution here?

Thanks in advance
User avatar
trendy
Posts: 222
Joined: Tue Feb 25, 2020 2:54 pm

Re: lighttp - redirect to other server in the same network

Post by trendy »

I don't know if this is the right way to do it, but you have defined http not https in the redirect.
Post Reply