Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Ngrok session expired (raspberry project)

Tags:

ngrok

raspbian

I've made a server on my raspberry and a mobile app to control it. I can connect to it when my mobile is connected to the same net, but I cannot do it outside of the net.

Actually I'm using ngrok to reach it but the session expires in 8 hours.

Is there any way to keep it on all the time I want? (or kind of, like a script that auto execute ngrok if the system detects that is not running)

And without ngrok how could I reach that server?

like image 337
DavidCG Avatar asked Jul 01 '18 09:07

DavidCG


People also ask

Do Ngrok sessions expire?

There's a bunch of things happening here, so let's break it down. Session Status and Session Expires – ngrok limits your sessions to eight hours on the free version. You can pay to get longer sessions.

How do you make Ngrok last forever?

If you sign up for an account on ngrok.com, whether free or paid, you will have tunnels that run with no time limit (aka "forever"). It is only limited to 2 hours for anonymous sessions, but if you sign up on the website and use an ngrok authtoken associated with that account, you will have no time limit.


1 Answers

You can keep the ngrok on all the time by using the authtoken. https://ngrok.com/docs#authtoken

First, go to ngrok website and login with an account. Then, go to the dashboard and get the token from Step 3 (Connect your account).

Run the command

ngrok authtoken <YOUR_TOKEN>
like image 76
Jun Ee Avatar answered Sep 24 '22 00:09

Jun Ee