Subsonic: podcast endpoints (getPodcasts, getNewestPodcasts, refreshPodcasts, createPodcastChannel, deletePodcastChannel/Episode, downloadPodcastEpisode)
This commit is contained in:
@@ -17,6 +17,7 @@ import (
|
||||
"git.noroutes.net/NoRoutes/vibetunes/internal/coverart"
|
||||
"git.noroutes.net/NoRoutes/vibetunes/internal/database"
|
||||
"git.noroutes.net/NoRoutes/vibetunes/internal/metadata"
|
||||
"git.noroutes.net/NoRoutes/vibetunes/internal/podcasts"
|
||||
"git.noroutes.net/NoRoutes/vibetunes/internal/scanner"
|
||||
"git.noroutes.net/NoRoutes/vibetunes/internal/subsonic"
|
||||
"git.noroutes.net/NoRoutes/vibetunes/internal/transcoding"
|
||||
@@ -82,6 +83,11 @@ func Open(cfg config.Config, log *slog.Logger) (*App, error) {
|
||||
Log: log,
|
||||
}
|
||||
|
||||
podcastMgr := podcasts.NewManager(db, cfg.DataDir, cfg.FFprobePath, log)
|
||||
if err := podcastMgr.RecoverInterruptedDownloads(); err != nil {
|
||||
log.Warn("podcast download recovery failed", "err", err)
|
||||
}
|
||||
|
||||
subsonicSrv := &subsonic.Server{
|
||||
DB: db,
|
||||
Config: cfg,
|
||||
@@ -89,6 +95,7 @@ func Open(cfg config.Config, log *slog.Logger) (*App, error) {
|
||||
Scanner: sc,
|
||||
CoverArt: covers,
|
||||
Transcoder: transcoding.NewManager(cfg.FFmpegPath),
|
||||
Podcasts: podcastMgr,
|
||||
Log: log,
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user