-
Notifications
You must be signed in to change notification settings - Fork 186
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Automated setup: cherrymusic [--conf KEY=VALUE [KEY=VALUE ...]] #665
Comments
Hey EWouters, you also have to include the section for the config key, separated by a dot. Please try to use I've updated the wiki to document this switch (see command line override): I'll close the issue now, feel free to reopen it, if this does not work as expected. |
Hey, thanks for clarifying! However, it does not seem to work as expected. I tried this:
So it says everything is ok, but the settings do not stick for some reason. Is this a bug? |
Perhaps there is a problem here because there is no config file when I call the function? edit: never mind, also when I call the command twice it doesn't work. |
Yeah, you are right, it seems you cannot run CM without a config file (even an empty file) right now. You could create a pull request that does not only check if the config file exists, but also allows to pass this test if the |
The thing is,
A good solution would be to respect the command line setting for media.basedir (or any other settings) when the config file gets auto-created on first run, like I think it does with the |
@tilboerner Correct, that is what I was expecting. So I'm reinstalling my server and I'm tackling the same problem again. Do you recommend me to write a script that I can pass the configuration value(s) to which will edit them in the configuration file or would it be feasible to make a pull request to add a Possible changes here, using this function? It seems this only needs to be a few lines of code. Am I very wrong here? |
@EWouters I wouldn't write code to edit the config file. Editing is non-trivial, because users can add their own comments to it, and back when all this code got written, there was no simple way to update the configuration file with Luckily, if I understand you correctly, this is exactly the moment you want to influence. You want to write the right configuration when the config file gets created. That should be doable. The files gets created using the configuration defaults. You can change that to also take into account the The whole things happens in the main script: Lines 200 to 204 in 911b757
The command line config options are in cherrymusic/cherrymusicserver/browsersetup.py Lines 47 to 55 in 911b757
Don't mind the You're right, it looks pretty straightforward. I'd be happy to receive a pull request, if you feel up to it. :) |
Hi, i installed CherryMusic on my raspberry pi (raspbian) and it works great!
However, I am looking for the documentation on how to automate the setup. I want to find out what arguments I can set with
python /opt/cherrymusic/cherrymusic [--conf KEY=VALUE [KEY=VALUE ...]]
I tried the documentation here, but I can't get it to work.
I could of course just edit the configuration file, but the build in method to set the config values seems more appealing.
I tried:
without succes. Can anyone point me in the right direction?
Thanks for the great work!
The text was updated successfully, but these errors were encountered: