Extend config with name, description, and pubkey

This commit is contained in:
Mike Dilger 2023-11-23 10:15:17 +13:00
parent 0a228680c2
commit ee40be7625
2 changed files with 9 additions and 0 deletions

View File

@ -1,4 +1,7 @@
Config(
ip_address: "127.0.0.1",
port: 8080,
name: None,
description: None,
public_key_hex: None,
)

View File

@ -4,6 +4,9 @@ use serde::{Deserialize, Serialize};
pub struct Config {
pub ip_address: String,
pub port: u16,
pub name: Option<String>,
pub description: Option<String>,
pub public_key_hex: Option<String>,
}
impl Default for Config {
@ -11,6 +14,9 @@ impl Default for Config {
Config {
ip_address: "127.0.0.1".to_string(),
port: 80,
name: None,
description: None,
public_key_hex: None,
}
}
}