Fix Docker volume mounts and database path for proper persistence
This commit is contained in:
@@ -51,7 +51,12 @@ const libraryPath = path.isAbsolute(config.libraryPath)
|
||||
? config.libraryPath
|
||||
: path.join(process.cwd(), config.libraryPath);
|
||||
app.use('/audio', express.static(libraryPath));
|
||||
app.use('/artwork', express.static(path.join(process.cwd(), 'artwork')));
|
||||
|
||||
// Artwork can be in data directory (Docker) or root (local)
|
||||
const artworkPath = process.env.NODE_ENV === 'production'
|
||||
? path.join(process.cwd(), 'data', 'artwork')
|
||||
: path.join(process.cwd(), 'artwork');
|
||||
app.use('/artwork', express.static(artworkPath));
|
||||
|
||||
// Health check
|
||||
app.get('/health', (req, res) => {
|
||||
|
||||
Reference in New Issue
Block a user