From dbba61efe7971f1022a72e2767b9b88b0281d829 Mon Sep 17 00:00:00 2001 From: Rakan Alhneiti Date: Mon, 9 Dec 2024 20:33:26 +0300 Subject: [PATCH] Add telemetry config --- src/citrea_config/rollup.rs | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/src/citrea_config/rollup.rs b/src/citrea_config/rollup.rs index 297aa73..ea960de 100644 --- a/src/citrea_config/rollup.rs +++ b/src/citrea_config/rollup.rs @@ -121,6 +121,8 @@ pub struct FullNodeConfig { pub da: BitcoinServiceConfig, /// Important pubkeys pub public_keys: RollupPublicKeys, + /// Telemetry config + pub telemetry: TelemetryConfig, } impl Default for FullNodeConfig { @@ -174,6 +176,25 @@ impl Default for FullNodeConfig { 84, 172, 112, 13, 54, 9, 206, 106, 138, 251, 218, 15, 28, 137, 112, 127, ], }, + telemetry: Default::default(), + } + } +} + +/// Telemetry configuration. +#[derive(Debug, Clone, PartialEq, Deserialize, Serialize)] +pub struct TelemetryConfig { + /// Server host. + pub bind_host: String, + /// Server port. + pub bind_port: u16, +} + +impl Default for TelemetryConfig { + fn default() -> Self { + Self { + bind_host: "localhost".to_owned(), + bind_port: 8081, } } }