-
Notifications
You must be signed in to change notification settings - Fork 46
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
[question] Start multiple instances of mpdris #89
Comments
For #89 and perhaps future testing. Note that this doesn't properly implement MPRIS' multi-instance layout; instead you get two completely independent players.
This should now work in git – specify a custom service name for the 2nd instance, e.g.
(There is also a |
Damn @grawity that was fast! I'm not sure I follow with the config though. I'm not using systemd at this computer (it's an oldish linux mint ditro) I have this in
Is this how I should configure multiple connections? |
Nevermind, I botched the installation. I see So I split the config into two, when I run the second instance I get this
|
Apparently older Python versions don't have read_file() yet. I kept the `with…` block though; we still want to abort if the file is missing, and it's a cheap way to do so. Ref #89
What version of Python are you using? I think I'll soon declare 2.x as no longer supported... And yes, you need one config file per instance. |
I use 2.7.6. I use the system installation and have mpdris also installed system-wise. I'm not too much of a python person but I know how to use virtualenv in a basic way, would that help me somehow to run this with newer version of python? |
Or... I guess I'll just put this into Docker :) I love putting things in Docker :D Would you be interested in having a docker version set up? |
@grawity currently (on commit 5362867), when bus name is neither given on command line nor in a config file (e.g. when no conf file exists), mdpris crashes because the variable is initialized to None:
|
Anyways, I can run multiple instances of mpdris in parallel with this systemd-user-unit:
No configuration file needed. |
I forgot that this is always /present/, so get() won't handle it. Ref #89
Fixed the crash. Most distributions have separate packages for Python 2.x series and 3.x series; the 3.x mpd module might be called "python-mpd2". |
This works for me so I think we can close? Thank you very much for implementing this. |
I currently use two mpd servers, one locally and one on a raspberry pi. I would like to be able to start two mpdris instances to control one or the other. Right now the older instance is replaced when I start another one.
The text was updated successfully, but these errors were encountered: