You are a devops or a software developer in a company and you are about to start hacking one program of the system.
At some point, you will ask yourself that question :
“How do I route the traffic to my local version of the application ?”
(unless if you test everything remotely)
Some obvious answers exist (‘use Docker’, ‘get nginx’, ‘use our homegrown proxy’).
But what if you just want to use the tiniest possible solution ? Something that would require only one command to start ?
=> type ‘
sudo npx local-traffic‘ in your terminal (sudo when run under linux / macOs). After 4 seconds, the proxy should be started.
There is a config file that you can modify (.local-traffic.json), actively watched by the proxy (so no need to reload/restart).
That proxy also takes care about a couple of neat things :
– cookies rewrite to keep them on the proxy domain (and to keep a session on a site)
– response body rewrite to get hyperlinks on the proxy
– SSL options (to be able to reach https sites)
More Information available at https://github.com/libetl/local-traffic