feat: Enable core to use local config files while being managed via the web (#1540)

This commit is contained in:
Mg Pig
2025-11-08 20:32:00 +08:00
committed by GitHub
parent b50744690e
commit 1273426009
24 changed files with 800 additions and 228 deletions

View File

@@ -8,7 +8,7 @@ use anyhow::Context as _;
use dashmap::DashMap;
use easytier::{
common::{
config::{ConfigLoader, NetworkIdentity, PeerConfig, TomlConfigLoader},
config::{ConfigFileControl, ConfigLoader, NetworkIdentity, PeerConfig, TomlConfigLoader},
scoped_task::ScopedTask,
},
defer,
@@ -391,7 +391,7 @@ impl HealthChecker {
.delete_network_instance(vec![cfg.get_id()]);
});
self.instance_mgr
.run_network_instance(cfg.clone(), false)
.run_network_instance(cfg.clone(), false, ConfigFileControl::STATIC_CONFIG)
.with_context(|| "failed to run network instance")?;
let now = Instant::now();
@@ -435,7 +435,7 @@ impl HealthChecker {
);
self.instance_mgr
.run_network_instance(cfg.clone(), true)
.run_network_instance(cfg.clone(), true, ConfigFileControl::STATIC_CONFIG)
.with_context(|| "failed to run network instance")?;
self.inst_id_map.insert(node_id, cfg.get_id());