Production-ready docker-compose for Connext routers.
- Docker CE (Community Edition) version 20.10.5 or higher
- Docker Compose version 1.27.4 or higher
- Clone repo
cd ~
git clone https://github.com/connext/router-docker-compose.git
- Rename file
.env.example
to.env
and modify it. You need to set next environment variables:
ROUTER_VERSION
- version to use, images found here: https://github.com/connext/nxtp/pkgs/container/router
Note: Do not use :latest
tag! This will not be stable as we are constantly updating! Find the latest Amarok release and use the version semver tagged, i.e. 0.2.1-beta.10
.
-
Go through
docker-compose.yml
and change any of the externally mapped ports if those ports do not work with your host configuration. -
Create configuration file
~/router-docker-compose/config.json, it will be mounted into router container. Use the
config.example.jsonfor guidance on what config items to change/modify. At minimum, please add your own paid RPC providers to the
providers` array for each chain, and verify the assets for the desired chains. See Connext docs for configuration description. -
Rename file
key.example.yaml
tokey.yaml
and modify it. Web3Signer yaml key file~/router-docker-compose/key.yaml
will be mounted into the signer container. Example file uses raw unencrypted files method. See Web3Signer docs. And for more custom commands of web3signer, edit~/router-docker-compose/data/signerConfig/config.yaml
. Refer Web3Signer Command docs -
Create docker-compose services, volumes and network.
cd ~/router-docker-compose
docker-compose create
- Run docker-compose stack.
docker-compose up -d
- Check the status.
docker-compose ps
OR
docker ps -a
- Check the logs.
docker-compose logs
OR
docker-compose logs router
You can also use these commands.
docker logs router
- Stop and delete containers.
docker-compose down
docker-compose restart
- Modify
.env
to changeROUTER_VERSION
- Update stack
docker-compose pull
docker-compose up -d