Skip to content

A simple HTTP redirector intended for private networks

Notifications You must be signed in to change notification settings

chriskillpack/http-redirector

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HTTP Redirector

A very simple HTTP redirector and terminating HTTPS proxy intended for private networks. I wrote this for personal use on my home network.

Redirects

It only redirects based on the host, incoming request to host foo./ is redirected to something.else:1234/bar/cat. It only supports temporary redirects.

HTTPS proxy

Allows you to serve an HTTP site as HTTPS, e.g. https://my-site-as-https.com will be proxied to http://my-http-site.com. The proxy can use a custom HTTPS cert for a proxy entry using cert and key.

TODO - Support path arithmetic

To build

Either go build http-redirector or use build.sh (which also builds an ARM version).

To run as a service

./http-redirector -service install
./http-redirector -service start

When using the option -service install the program will copy the value of -config into the service configuration. So if you want the service to run with a different config file:

./http-redirector -service install -config /path/to/myconfig.toml

Config hot reload

Sending the SIGHUP signal to the service will cause it to reload and apply configuration:

kill -HUP {PID}

About

A simple HTTP redirector intended for private networks

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published