Skip to content

Instantly share code, notes, and snippets.

@ifnull
Created October 8, 2017 04:53
Show Gist options
  • Select an option

  • Save ifnull/6a1f6602c99816757f65a26c278a1dce to your computer and use it in GitHub Desktop.

Select an option

Save ifnull/6a1f6602c99816757f65a26c278a1dce to your computer and use it in GitHub Desktop.

Revisions

  1. Daniel Smith created this gist Oct 8, 2017.
    15 changes: 15 additions & 0 deletions README.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,15 @@
    ```
    apt-get install supervisor ngrok
    ```

    Create the config files
    * /root/.ngrok2/ngrok.yml
    * /etc/supervisor/conf.d/ngrok.conf

    ```
    supervisorctl reread
    supervisorctl update
    supervisorctl restart all
    ```

    Check dashboard for tunnel status
    7 changes: 7 additions & 0 deletions ngrok.conf
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,7 @@
    [program:ngrok]
    command=/bin/ngrok start --all -log stdout --authtoken YOUR_AUTH_TOKEN -config=/root/.ngrok2/ngrok.yml
    stdout_logfile=/var/log/ngrok.out.log
    stderr_logfile=/var/log/ngrok.err.log
    autostart=true
    autorestart=true
    stopsignal=QUIT
    6 changes: 6 additions & 0 deletions ngrok.yml
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,6 @@
    authtoken: YOUR_AUTH_TOKEN
    web_addr: 0.0.0.0:4040
    tunnels:
    ssh:
    proto: tcp
    addr: 0.0.0.0:22