0.6.0 • Published 3 months ago

nsite-ts v0.6.0

Weekly downloads
-
License
MIT
Repository
-
Last release
3 months ago

nsite-ts

A Typescript implementation of nsite

Running with docker-compose

git clone https://github.com/hzrd149/nsite-ts.git
cd nsite-ts
docker compose up

Once the service is running you can access the cached version at http://localhost:8080

If you need to test, you can directly access the ts server at http://localhost:3000

Connecting to Tor and I2P relays

nsite-ts supports ALL_PROXY and other proxy env variables here

Install Tor (Documentation) and I2Pd (Documentation)

Create a proxy.pac file

// SPDX-License-Identifier: CC0-1.0

function FindProxyForURL(url, host)
{
  if (shExpMatch(host, "*.i2p"))
  {
    return "PROXY 127.0.0.1:4444; SOCKS5 127.0.0.1:4447";
  }
  if (shExpMatch(host, "*.onion"))
  {
    return "SOCKS5 127.0.0.1:9050";
  }
  return "DIRECT";
}

Start server with PAC_PROXY variable

PAC_PROXY=file://$(pwd)/proxy.pac node .