Ngrok Related knowledge

Source: Internet
Author: User
Tags syslog

One. Ngrok background Run

Nohup./ngrokd-domain="xxx.xxx.xxx" &

Two. Ngrok Boot up

1. In the Ngrok directory, create a new start.sh

Content is

Path=/home/pi/web/ngrok

Nohup $path/ngrok-config $path/ngrok.cfg-subdomin * * * 80

2. Add the Ngrok program as a system service

Create a new service item (Ngrok) under the/ETC/INIT.D directory

sudo vim Ngrok

  1. #!/bin/sh
  2. # # # BEGIN INIT INFO
    # Provides:ngrok
    # Required-start: $remote _fs $syslog
    # required-stop: $remote _fs $syslog
    # Default-start:2 3 4 5
    # default-stop:0 1 6
    # Short-description:start Ngrok at boot time
    # Description:enable service provided by Ngrok.
    # # # END INIT INFO

  3. Ngrok_path=/home/pi/web/ngrok
  4. Case "$" in
  5. Start
  6. echo "Start Ngrok service ..."
  7. SH ${ngrok_path}/start.sh
  8. ;;
  9. *)
  10. Exit 1
  11. ;;
  12. Esac

3. Give permission to execute and update the service

sudo chmod 755 Ngrok

sudo update-rc.d ngrok defaults

Setup is complete, restart the machine to see if there is a normal.

Ngrok Related knowledge

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.