More > JRiver Media Center 32 for Linux

docker image works great but no mcws access

<< < (2/3) > >>

mattkhan:

--- Quote from: zeltak on March 24, 2024, 04:09:26 pm ---
any clue guys?


--- End quote ---
try wrapping the url in single quotes or using


--- Code: ---alias curl='noglob curl'

--- End code ---

zybex:

--- Quote from: zeltak on March 24, 2024, 04:09:26 pm ---curl http://192.168.1.37:52199/MCWS/v1/Control/MCC\?Command\=10000 -O /dev/null

it simply does nothing and the CLI show an error

zsh: no such file or directory: http://192.168.1.37:52199/MCWS/v1/Control/MCC?Command=10000

--- End quote ---

It's lowercase -o /dev/null.
Uppercase -O is telling it to write to a file called "MCC\?Command\=10000" or similar (perhaps the full URL as a filename, depends on curl variant), which cannot be created, or you're running in a folder with no write permissions.
Also, not sure you need to escape the ? and = symbols.

mattkhan:

--- Quote from: zybex on March 28, 2024, 04:45:35 pm ---Also, not sure you need to escape the ? and = symbols.

--- End quote ---
you do need to escape the ? in zsh (or quote the URL or use noglob)

zeltak:
Hi all really appreciate all the comments but I think im more confused then ever and nothings works haha

so I have MC setup in a docker on my nas (192.168.1.37), which will never play anything just serve files to MBP and MB air.

I have been using a local library for years on Mac with curl commands to control/intereact with MC, ie


--- Code: ---curl http://localhost:52199/MCWS/v1/Control/MCC\?Command\=10000 -O /dev/null
--- End code ---

but playback is done ie via MC on MBP

now im confused :

1) do I need to run this command still on MBP (localhost) or do I need to run it on the server, ie:


--- Code: ---curl http://192.168.1.37:52199/MCWS/v1/Control/MCC\?Command\=10000 -O /dev/null
--- End code ---


2) how do I authenticate? I cant for the life of me get it to work after I enabled authentication (since starting to use a "server") at all

I tried this


--- Code: ---curl http://USER:PASS:localhost:52199/MCWS/v1/Control/MCC\?Command\=10000 -O /dev/null
--- End code ---

but dosent seem to work

any help would be truly appreciate as im totally lost :)

best

Z

mattkhan:

--- Quote from: zeltak on March 29, 2024, 12:20:09 pm ---but playback is done ie via MC on MBP

--- End quote ---
do you mean you now have 2 instances of MC? one is the server which is running in docker, the other running locally on the MBP and which is actually playing content?

if so, you have 2 choices

1) tell the server to be able to control client zones, send the command to the server targeting the client zone (this will be easier to do using a more explicit command like MCWS/v1/Playback/Pause)
2) enable media server on the client, send the command to localhost as you have been doing since forever

probably 2) is simpler


--- Quote from: zeltak on March 29, 2024, 12:20:09 pm ---2)I tried this


--- Code: ---curl http://USER:PASS:localhost:52199/MCWS/v1/Control/MCC\?Command\=10000 -O /dev/null
--- End code ---

--- End quote ---

basic auth is http://USER:PASS@localhost:52199/etc

or curl -u USER:PASS http://localhost:52199/etc

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version