Document toolboxDocument toolbox

Install Devo Relay with docker-compose

We provide a docker-compose configuration file that can be used to run both the relay and the CLI images available in DockerHub.

Before you begin

Make sure you can provide a host machine with the requirements specified in this article.

As we will use docker to run the relay, the following additional requirements have to be met:

  • docker daemon

  • Your docker-compose version must be higher than or equal to 1.27

Preparation

  1. Clone this repository in the machine where you want to install the relay.

  2. Create new folders for config, local logs, and disk buffer in the same folder where the docker-compose.yml file is located.

    mkdir conf buffer logs
  3. The folders above must have write and execute permissions for 'others'.

    sudo chmod 777 conf/ buffer/ logs/
  4. Edit the environment file:

To work with this docker-compose file, some environment variables need to be set. For this purpose, there is an environment file .env in which you can set them. There is a short description of each of them below:

Name

Mandatory

Default value

   Description

Name

Mandatory

Default value

   Description

NG_RELAY_VERSION

Yes

<LAST_VERSION_PUBLISHED>

The version of the Devo NG-Relay.

LOG_LEVEL

No

info

Sets the log level for the Devo NG-Relay.

JAVA_OPTS

No

-Xmx1G -Xms1G

Space-separated quoted list in which you can activate/deactivate any of the JVM flags.

TCP_PORT_RANGE

No

13003-13020

Used to open the TCP ports specified in all the user-defined rules.

UDP_PORT_RANGE

No

13003-13020

Used to open the UDP ports specified in all the user-defined rules.

NG_RELAY_CLI_VERSION

Yes

<LAST_VERSION_PUBLISHED>

The version of the Devo NG-Relay CLI.

Start the relay

Run the following command:

docker-compose run --rm devo-ng-relay-cli

Once the images are downloaded, both the relay and the CLI containers will be started.

The first time a relay is started, you will have to perform the setup process using the CLI. To do it, follow the steps indicated in Set up your relay.

The CLI prompt will always be shown when executing this command. You can type exit when you are done with the CLI. The relay container will continue up and running. 

Stop the relay

To stop and destroy all the containers and networks created before, run the following command:

Note that the relay configuration will remain available as it is stored outside the containers. Using the start command above will start the relay again using the existing configuration. 

Check the relay logs

To check the relay container logs, use this command: