mirror of
https://github.com/mofeng-git/One-KVM.git
synced 2026-07-30 08:41:44 +08:00
feat: 实现 Redfish API 标准接口;支持通过前端开关控制 Redfish 服务
This commit is contained in:
@@ -110,6 +110,8 @@ pub struct AppConfig {
|
||||
pub rustdesk: RustDeskConfig,
|
||||
/// RTSP streaming settings
|
||||
pub rtsp: RtspConfig,
|
||||
/// Redfish API settings
|
||||
pub redfish: RedfishConfig,
|
||||
}
|
||||
|
||||
/// Authentication configuration
|
||||
@@ -808,3 +810,18 @@ impl Default for WebConfig {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Redfish API configuration
|
||||
#[typeshare]
|
||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||
#[serde(default)]
|
||||
pub struct RedfishConfig {
|
||||
/// Enable Redfish API endpoint
|
||||
pub enabled: bool,
|
||||
}
|
||||
|
||||
impl Default for RedfishConfig {
|
||||
fn default() -> Self {
|
||||
Self { enabled: false }
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user