mirror of
https://github.com/telemt/telemt.git
synced 2026-11-03 22:31:59 +03:00
WEB: Resolve opt-in decoy hostnames during config preparation #929
Co-Authored-By: brekotis <93345790+brekotis@users.noreply.github.com>
This commit is contained in:
@@ -95,8 +95,8 @@ pub(super) async fn bootstrap(
|
||||
std::process::exit(1);
|
||||
}
|
||||
|
||||
let mut config = match ProxyConfig::load(&config_path) {
|
||||
Ok(c) => c,
|
||||
let mut config = match ProxyConfig::load_prepared(config_path.clone()).await {
|
||||
Ok(loaded) => loaded.config,
|
||||
Err(e) => {
|
||||
if config_path.exists() {
|
||||
eprintln!("[telemt] Error: {}", e);
|
||||
|
||||
@@ -512,6 +512,7 @@ pub(crate) fn deferred_process_fields(
|
||||
|
||||
fn configs_equal(old: &ProxyConfig, new: &ProxyConfig) -> bool {
|
||||
serde_json::to_value(old).ok() == serde_json::to_value(new).ok()
|
||||
&& old.web_decoy_endpoints_equal(new)
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
|
||||
Reference in New Issue
Block a user