README.md

http_helper

OVERVIEW

A simple node.js redirector and proxy application. Given a config file full of
redirect and proxy mappings, this application will match incoming HOST headers
and take the appropriate action by 301/302 redirecting or proxying.,ss

This is useful for redirecting www to root domains, redirecting old domains
to new domains, proxying for SSL from non-SSL sources on AWS.

PREREQUISITES

node.js (v0.10.28 preferred)

npm (comes with node.js)

PREFLIGHT

mv ./config-json.dist to ./config.json

Update mappings for redirects/proxies based on your needs

As an example, if we wanted to setup a redirect to yourdomain.com
from www.yourdomain.com, we would add the following block in config.json:
"www.yourdomain.com": {
"host": "http://yourdomain.com",
"code": 301,
"function": "redirect"
},
(Note: The function setting can be either redirect or proxy)