2019-08-29 14:46:54 -07:00
|
|
|
//! Zebrad Config
|
|
|
|
//!
|
|
|
|
//! See instructions in `commands.rs` to specify the path to your
|
|
|
|
//! application's configuration file and/or command-line options
|
|
|
|
//! for specifying it.
|
|
|
|
|
|
|
|
use serde::{Deserialize, Serialize};
|
|
|
|
|
2020-06-17 14:44:24 -07:00
|
|
|
/// Configuration for `zebrad`.
|
|
|
|
///
|
|
|
|
/// The `zebrad` config is a TOML-encoded version of this structure. The meaning
|
|
|
|
/// of each field is described in the documentation, although it may be necessary
|
|
|
|
/// to click through to the sub-structures for each section.
|
2019-12-20 11:20:04 -08:00
|
|
|
#[derive(Clone, Default, Debug, Deserialize, Serialize)]
|
2020-06-18 13:34:05 -07:00
|
|
|
#[serde(deny_unknown_fields, default)]
|
2019-08-29 14:46:54 -07:00
|
|
|
pub struct ZebradConfig {
|
2020-08-19 19:25:46 -07:00
|
|
|
/// Consensus configuration
|
2022-10-24 16:39:00 -07:00
|
|
|
pub consensus: zebra_consensus::Config,
|
2020-08-19 19:25:46 -07:00
|
|
|
|
2020-02-14 13:38:33 -08:00
|
|
|
/// Metrics configuration
|
2022-10-24 16:39:00 -07:00
|
|
|
pub metrics: crate::components::metrics::Config,
|
2020-07-20 22:31:11 -07:00
|
|
|
|
|
|
|
/// Networking configuration
|
2022-10-24 16:39:00 -07:00
|
|
|
pub network: zebra_network::Config,
|
2020-07-20 22:31:11 -07:00
|
|
|
|
|
|
|
/// State configuration
|
2022-10-24 16:39:00 -07:00
|
|
|
pub state: zebra_state::Config,
|
2020-07-20 22:31:11 -07:00
|
|
|
|
|
|
|
/// Tracing configuration
|
2022-10-24 16:39:00 -07:00
|
|
|
pub tracing: crate::components::tracing::Config,
|
2020-10-23 18:56:54 -07:00
|
|
|
|
|
|
|
/// Sync configuration
|
2022-10-24 16:39:00 -07:00
|
|
|
pub sync: crate::components::sync::Config,
|
2021-10-07 15:47:37 -07:00
|
|
|
|
|
|
|
/// Mempool configuration
|
2022-10-24 16:39:00 -07:00
|
|
|
pub mempool: crate::components::mempool::Config,
|
2022-02-22 03:26:29 -08:00
|
|
|
|
|
|
|
/// RPC configuration
|
2022-10-24 16:39:00 -07:00
|
|
|
pub rpc: zebra_rpc::config::Config,
|
2022-10-31 17:43:45 -07:00
|
|
|
|
|
|
|
#[cfg(feature = "getblocktemplate-rpcs")]
|
|
|
|
/// Mining configuration
|
|
|
|
pub mining: zebra_rpc::methods::get_block_template_rpcs::config::Config,
|
2020-10-23 18:56:54 -07:00
|
|
|
}
|