# 0. Prepare

We will need to access the following public network addresses. If your network has a firewall, you need to add proper rules to white list them.

openresty.com 443 
openresty.org 443 
pkg.openresty.com 443 
api.openresty.com 443 

We need to prepare the following files.

  • openresty-edge-config-[% version-number %].rpm or openresty-edge-config-[% version-number %].deb

# 1. Installation

  • Copy openresty-edge-config to the current directory

  • Download the installation script:

    curl -O https://openresty.com/client/oredge/install-edge-cli.sh
    

    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 https://openresty.com/client/oredge/install-edge-cli.sh
    

    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.

  • Execute the installation script:

    sudo /bin/bash -x install-edge-cli.sh
    

# 2. Set path

please set PATH envrioment in ~/.bash_profile.

export PATH=/usr/local/oredge-admin/bin:$PATH

# 3. Add config to ~/.oredge/config.

mkdir ~/.oredge

cat << EOF > ~/.oredge/config
[admin]
host=admin-dev.openresty.com
port=443
verify_ssl=true
api_token=xxxxxxxxxxxxxxxxxxxxxx
EOF

# 4. Try cli

oredge --help