πΈοΈ The Webb Relayer π§β
git clone https://github.com/webb-tools/relayer.git
cargo build --release
Ideal for development, Run a relayer for a local substrate node that integrates our pallets: webb-standalone-node
Run the relayer with our preset configuration like so:
./target/release/webb-relayer -c config/local-substrate -vvvv
Webb Relayer is easy to run and with flexible config π, to test it out first you have to create a config file
Example:
- Create a .env file with the following values for the networks you wish to support
WEBB_EVM_<network>_ENABLED=true
WEBB_EVM_<network>_PRIVATE_KEY=<0X_PREFIXED_PRIVATE_KEY>
WEBB_EVM_<network>_BENEFICIARY=<0X_PREFIXED_ADDRESS>
Checkout config for useful default configurations for many networks. These config files can be changed to your preferences, and are enabled with the .env configuration listed above.
Then Simply run
webb-relayer -vvv -c ./config
Hot Tip πΆοΈ: you could also use the json format for the config files if you prefer that, and it would work!
To Use Docker in and to run the relayer on any cloud provider, all you need is to create your configuration and .env files
as it is shown above, save it into a config
directory then you run the following command:
docker run --rm -v "<ABSOLUTE_PATH_TO_CONFIGS_DIRECTORY>:/config" --env-file .env -p 9955:9955 ghcr.io/webb-tools/relayer:edge
Note: this uses the latest and pre-released version deployed from
main
branch, changeedge
to the latest stable release version.
This will mount a configuration files at the /config
directory inside the container so it would allow it to read the configuration you added.
- src/
- events_watcher/: Sync to different network types (EVM, Substrate), and act on different events.
- store/: Logic for storing information with different backends.
- config.rs: Functionality related to parsing of configurable values.
- context.rs: Access the parsed configuration and generate providers and wallets.
- handler.rs: Logic for what to do when a client is interacting with this relayer.
- main.rs: Build and start the relayer.
- service.rs: The entry for tasks once the relayer is operating.
- tx_queue.rs: A transaction queue for orderly handling of transactions.
This crate uses #![deny(unsafe_code)]
to ensure everything is implemented in
100% Safe Rust.
Want to join us? take a look at some of these issues:
Licensed under Apache 2.0 license.Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this crate by you, as defined in the Apache 2.0 license, shall be licensed as above, without any additional terms or conditions.