0

I want to use pyngrok's .connect function to route the connection to a specific ip address like 192.168.0.171 instead of the default local host. I've read through the documentation but cannot find anything relevant.

tunnel = ngrok.connect(25565,"tcp")

how do I add the IP address here?

ive tried to put the ip address as a parameter but it just returns a syntax error, can anyone help me change the local host to the ip address: 192.168.0.171

`"tcp://0.tcp.ngrok.io:12345" -> "localhost:22"`

1 Answers1

0

You can pass the IP address:port to the connect method as the first argument like this:

tunnel = ngrok.connect("192.168.0.171:25565", "tcp")
D Malan
  • 10,272
  • 3
  • 25
  • 50