Install OpenResty Edge Node

1. Preparation

If your network has a firewall, you need to add the following whitelist. 443 443 443

2. Copy openresty-edge-config to the current directory

3. Download the installation script

curl -O

If you get a message like the following:

curl: command not found

It is possible that curl is not installed on the system or that the system shell program does not contain a search path for curl.

You can use absolute paths to retry.

/usr/bin/curl -O

Your system’s path may be different, contact your webmaster or use a command such as which bash to check the path to correct the situation.

4. Execute the installation script

sudo /bin/bash

It may take a few minutes to run next, so please be patient. Upon successful installation, you will see that the last line of output from this command is:

Great! OpenResty Edge Node installed successfully.

This script will automatically install the openresty-edge-node package and its dependencies, start the oredge-node service automatically, and set the oredge-node service to run automatically on boot.

The details can be found in the source code in the file.

In addition, the oredge-node service is started by:

sudo systemctl start oredge-node

Stop the service by:

sudo systemctl stop oredge-node

Restart the service by:

sudo systemctl start upgrade-oredge-node

The restart uses the binary upgrade method of nginx, so there is no down time.

5. Modify the edge-node configuration file /usr/local/oredge-node/conf/config.ini

# NOTICE: please feel free to edit these configurations if necessary.


# admin server host, default:
host = "ADMIN_HOST"
port = "ADMIN_PORT"


# log server host, default:

After modifying the configuration file, execute the following restart service:

sudo systemctl start upgrade-oredge-node

6. Check the error log file for nginx on the node at /usr/local/oredge-node/logs/error.log

tail /usr/local/oredge-node/logs/error.log

If you see the last two error logs like the one below, it is perfectly normal because the newly deployed nodes need to be approved on the Admin site before they can be added to the gateway cluster.

2017/05/25 22:19:43 [warn] 2550#2550: *4 [lua] init.lua:112:
init_worker(): node is not registered, contacting admin, context:

2017/05/25 22:19:44 [warn] 2554#2554: *5 [lua] privileged.lua:190:
could not establish node identity: awaiting approval, context:

This completes the installation of OpenResty Edge Node.

Now, you can use the installed Edge Node.

  1. Login to Admin website:

    URL: https://ADMIN_HOST

    If you are trying Edge, the URL and account password for Admin will be sent with your trial email.

    For the trial version, admin is deployed on our machines, while for the future purchase of the full version, we will provide the installation package for self-deployment.

  2. After login, go to the gateway clusters tab, there you will see the join request from the newly deployed node.

    According to the information in the join request, confirm that it is your own node, and then click approve.

    The procedure of approval is to add a new node to a gateway cluster. So before you approve, you need to create a cluster on the GUI, and then you can choose when you approve.

After the edge node service is deployed according to the above documents, openresty edge is up and running.

Start the OpenResty Edge service

We provide online documents, and related blog posts and corresponding video tutorials.

If you have any questions, please contact us.