Minimal subsonic functionality
All checks were successful
CI / check (push) Successful in 1m12s
CI / docker (push) Successful in 2m2s

This commit is contained in:
Connor Johnstone
2026-03-20 20:04:35 -04:00
parent 0496944923
commit 43f4dad038
5 changed files with 50 additions and 3 deletions

View File

@@ -38,6 +38,9 @@ pub struct AppConfig {
#[serde(default)]
pub scheduling: SchedulingConfig,
#[serde(default)]
pub subsonic: SubsonicConfig,
}
#[derive(Debug, Clone, Serialize, Deserialize)]
@@ -152,6 +155,26 @@ pub struct SchedulingConfig {
pub monitor_interval_hours: u32,
}
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct SubsonicConfig {
/// Whether the Subsonic API is enabled.
#[serde(default = "default_true")]
pub enabled: bool,
/// Whether transcoding via ffmpeg is enabled.
#[serde(default = "default_true")]
pub transcoding_enabled: bool,
}
impl Default for SubsonicConfig {
fn default() -> Self {
Self {
enabled: true,
transcoding_enabled: true,
}
}
}
impl Default for SchedulingConfig {
fn default() -> Self {
Self {
@@ -179,6 +202,7 @@ impl Default for AppConfig {
indexing: IndexingConfig::default(),
metadata: MetadataConfig::default(),
scheduling: SchedulingConfig::default(),
subsonic: SubsonicConfig::default(),
}
}
}