Page 1 of 1

addMediaFolder REST API missing

PostPosted: Sun Nov 19, 2017 11:28 am
by svg

At present, the only way to initialize media folders upon installation of a fresh Subsonic instance is by going to the web GUI.

It seems that there should be a corresponding REST API call /addMediaFolder, as long as such API exist for /startScan, /changePassword, etc (also can be done in GUI).

My use case (should be quite common):

1. when you run Subsonic in a Docker container, after starting the container you need to manually add media folders through GUI
2. but the whole idea with automation is that you should be able to configure everything through the scripts with REST API calls

My script would:
1. start the Docker container
2. /changePassword
3. /addMediaFolder, (missing)
4. /startScan

Maybe there is a workaround? I was thinking of (I am using MySQL) to adjust the music_folder, music_folder_user,... tables manually, but I am afraid of breaking the DB integrity.

Thanks in advance!

Re: addMediaFolder REST API missing

PostPosted: Sat Jul 14, 2018 12:01 pm
by jol
imho this is the wrong direction. One should separate code (in containers) from persistent data (on volumes). Most of the containers I used so far had
persistence (configuration and data) in /var/productname including a docker-compose script. For subsonic it would be an option to have
/var/subsonic/mediamount as part of that structure, and anyone can just mount or link whatever he wants there and do a rescan once.

having written that I want to express, that I´d love to see a kind of official subsonic container listed at There is a huge number on docker hub, but you never know what´s inside or working.. and in fact it is just redundant. Whether you start from Ubuntu or Alpine or anything is not that important to me.

Thanks, Joachim