mirror of
https://github.com/sigp/lighthouse.git
synced 2026-04-16 20:39:10 +00:00
Add Eth2Config to runtime
This commit is contained in:
@@ -4,26 +4,22 @@ use network::NetworkConfig;
|
||||
use serde_derive::{Deserialize, Serialize};
|
||||
use std::fs;
|
||||
use std::path::PathBuf;
|
||||
use types::ChainSpec;
|
||||
|
||||
/// The core configuration of a Lighthouse beacon node.
|
||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||
pub struct ClientConfig {
|
||||
pub data_dir: String,
|
||||
pub spec_constants: String,
|
||||
pub db_type: String,
|
||||
db_name: String,
|
||||
pub network: network::NetworkConfig,
|
||||
pub rpc: rpc::RPCConfig,
|
||||
pub http: HttpServerConfig, //pub ipc_conf:
|
||||
pub spec: ChainSpec,
|
||||
pub http: HttpServerConfig,
|
||||
}
|
||||
|
||||
impl Default for ClientConfig {
|
||||
fn default() -> Self {
|
||||
Self {
|
||||
data_dir: ".lighthouse".to_string(),
|
||||
spec_constants: "testnet".to_string(),
|
||||
db_type: "disk".to_string(),
|
||||
db_name: "chain_db".to_string(),
|
||||
// Note: there are no default bootnodes specified.
|
||||
@@ -31,7 +27,6 @@ impl Default for ClientConfig {
|
||||
network: NetworkConfig::new(vec![]),
|
||||
rpc: rpc::RPCConfig::default(),
|
||||
http: HttpServerConfig::default(),
|
||||
spec: ChainSpec::minimal(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user