Configuration Options

The race-env module provides utilities for managing and accessing configuration options for the Transactor and other Race Protocol components. These options are typically defined in a TOML configuration file and allow developers to customize the behavior of their Race deployments.

Transactor Configuration Options

The Transactor configuration file includes the following options:

  • port: This specifies the port on which the Transactor server listens for incoming connections.

  • endpoint: This defines the public endpoint or URL used by clients and other servers to connect to the Transactor.

  • chain: This specifies the blockchain network on which the Transactor operates (e.g., "solana", "facade").

  • address: This defines the on-chain address of the server account associated with the Transactor.

  • reg_addresses: This is a list of registration account addresses that the Transactor will scan to discover and serve games.

  • disable_blacklist: This optional boolean flag determines whether the Transactor uses a local blacklist to prevent loading of malformed game addresses.

  • debug_mode: This optional boolean flag enables debug mode, which may provide additional logging and information for development and testing purposes.

Other Configuration Options

The race-env module also provides access to configuration options for other components, such as:

  • Facade server: This includes the server's host address and the default registration address used for testing and development.

  • Solana network: This includes the RPC endpoint and path to the keyfile used for interacting with the Solana blockchain.

Usage

Developers can specify the path to the configuration file when running the Transactor or other Race components. The race-env module then parses the TOML file and provides access to the configured options. Additionally, the module offers helper functions for determining default values based on the chain type and environment.

By customizing the configuration options, developers can tailor their Race deployments to their specific needs and environments, ensuring optimal performance and security.

Last updated