Skip to content

Latest commit

 

History

History
 
 

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

README.md

Installing ngrok on Ubuntu

  • Author: Pedric Kng
  • Updated: 26 Jun 2020

Installation

Snap is a simple way to install

  1. Install snap
sudo apt update
sudo apt install snapd
  1. Install ngrok via snap
sudo snap install ngrok

Ngrok Configuration

Create the ngrok configuration as per ngrok documentation

Sample ngrok configuration

Note: the 'web_addr' configuration refers to ngrok web console. By default, it is set to localhost for ubuntu interactive mode-only (UI). For pure console, change it to an external url/ip address.

web_addr: 192.168.137.47:4040

Config as service

  1. Create a Ngrok service file in /etc/systemd/system/

Enable ngrok service

sudo systemctl daemon-reload
sudo systemctl enable ngrok.service

Start ngrok service

sudo systemctl start ngrok

Check if ngrok service is up

sudo systemctl status ngrok

Check ngrok service version

ngrok --version

Inspecting the traffic through tunnel

ngrok http 8080

Extract the tunnel url

  1. Browse to http:\localhost:4040 for the ngrok console.

  2. Query via ngrok rest api

curl http://192.168.137.47:4040/api/tunnels

References

Install ngrok using snap [1]
How to Get Public IP Address by Using Ngrok or SSH Tunneling [2]