Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to change ngrok's web interface port address (not 4040)?

ngrok's awesome web interface is pointed to http://127.0.0.1:4040 by default. I have other applications listening on that port, however, and need to change it so that ngrok listens on, say, http://127.0.0.1:4045.

like image 861
zelusp Avatar asked Mar 15 '16 17:03

zelusp


People also ask

How do I change my Ngrok web interface port?

Download and install ngrok to make your local server accessible remotely. $> cd /path/to/your-project-folder $> ngrok 8080 Copy the public URL ngrok gives you and try running it through PageSpeed Insights!

What is Web interface in Ngrok?

ngrok's local web interface has a dedicated status page that shows configuration and metrics information about the running ngrok process. You can access it at http://localhost:4040/status.


1 Answers

Create a config.yml wherever ngrok is looking for its default config on your platform. If the directory doesn't exist, make it (on windows this is done by entering .ngrok2. as the folder name).

OS X /Users/example/.ngrok2/ngrok.yml

Linux /home/example/.ngrok2/ngrok.yml

Windows C:\Users\example\.ngrok2\ngrok.yml

Then, in config.yml enter

web_addr: 4045

Since this file is in ngrok's default config directory running ngrok http 1337 from the command line, for example, will now run ngrok listening to your server at port 1337 and serving its web interface on http://127.0.0.1:4045

like image 88
zelusp Avatar answered Sep 20 '22 20:09

zelusp