Struct humphrey_server::config::Config [−][src]
pub struct Config {Show 17 fields
pub address: String,
pub port: u16,
pub threads: usize,
pub mode: ServerMode,
pub blacklist: Vec<String>,
pub blacklist_mode: BlacklistMode,
pub log_level: LogLevel,
pub log_console: bool,
pub log_file: Option<String>,
pub cache_limit: usize,
pub cache_time_limit: u64,
pub directory: Option<String>,
pub websocket_proxy: Option<String>,
pub proxy_target: Option<String>,
pub load_balancer_targets: Option<Vec<String>>,
pub load_balancer_mode: Option<LoadBalancerMode>,
pub raw: HashMap<String, String>,
}
Expand description
Stores the server configuration.
Fields
address: String
Address to host the server on
port: u16
Port to host the server on
threads: usize
Threads to host the server using
mode: ServerMode
Routing mode of the server
blacklist: Vec<String>
Blacklisted IP addresses
blacklist_mode: BlacklistMode
Mode of blacklisting
log_level: LogLevel
Log level of the server
log_console: bool
Whether to log to the console
log_file: Option<String>
Logging output file
cache_limit: usize
Size limit of the in-memory file cache, measured in bytes
cache_time_limit: u64
Time limit for cached items
directory: Option<String>
Root directory to serve files from
websocket_proxy: Option<String>
WebSocket proxy address
proxy_target: Option<String>
Proxy target address
load_balancer_targets: Option<Vec<String>>
Targets for the load balancer
load_balancer_mode: Option<LoadBalancerMode>
Algorithm for load balancing
raw: HashMap<String, String>
Raw configuration hashmap