Skip to content

Instantly share code, notes, and snippets.

@pmalek
Last active August 29, 2015 13:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pmalek/8756997 to your computer and use it in GitHub Desktop.
Save pmalek/8756997 to your computer and use it in GitHub Desktop.
var httpProxy = require('http-proxy'),
fs = require('fs');
console.log("proxy");
var options = {
target: "https://localhost",
ssl: {
key: fs.readFileSync('./ssl/key.pem'),
cert: fs.readFileSync('./ssl/cert.pem')
},
ws: true,
secure: true,
xfwd: true
};
var proxy = httpProxy.createServer(options);
proxy.listen(80);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment