Build Status Coverage Status Python 3.8 Django 3

Gnosis Safe Relay Service

This service allows us to have owners of the Safe contract that don’t need to hold any ETH on those owner addresses. How is this possible? The transaction relay service acts as a proxy, paying for the transaction fees and getting it back due to the transaction architecture we use. It also enables the user to pay for ethereum transactions using ERC20 tokens.

Docs

Docs are available on Gnosis Docs You can open the diagrams explaining Pre CREATE2 deployment under docs/ with Staruml

Setup for development (using ganache)

This is the recommended configuration for developing and testing the Relay service. docker-compose is required for running the project.

Configure the parameters needed on .env_ganache. By default the private keys of the accounts are the ones from Ganache, and the contract addresses are calculated to be the ones deployed by the Relay when the application starts, so there's no need to configure anything.

More parameters can be added to that file like:

Then:

docker-compose -f docker-compose.yml -f docker-compose.dev.yml build --force-rm
docker-compose -f docker-compose.yml -f docker-compose.dev.yml up

The service should be running in localhost:8000

Setup for production

This is the recommended configuration for running a production Relay. docker-compose is required for running the project.

Configure the parameters needed on .env. These parameters need to be changed:

Another parameters can be configured like:

Then:

docker-compose build --force-rm
docker-compose up

The service should be running in localhost:8000

For example, to set up a Göerli node:

Run:

docker-compose build --force-rm
docker-compose up

You can test everything is set up:

curl 'http://localhost:8000/api/v1/about/'

Use admin interface

Services come with a basic administration web ui (provided by Django). A user must be created first to get access:

docker exec -it safe-transaction-service_web_1 bash
python manage.py createsuperuser

Then go to the web browser and navigate to http://localhost:8000/admin/

Contributors