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
feat(jukebox): use mpv over ipc as a player backend #211
Conversation
17f5a19
to
182c96e
Compare
4d584e1
to
e8759cb
Compare
6a96be2
to
6e6404a
Compare
70654f3
to
f3ad3fd
Compare
695a55a
to
7b05545
Compare
feec3a5
to
9ec7480
Compare
Could the documentation on using it with docker be updated with the mpv changes? please 😅 |
@marlop352 hm that shouldn't have changed. are you getting some sort of error? |
@sentriz yes, I'm getting this:
my docker compose in case I'm doing something dumb:
|
hmm interesting, can you try make this change to your compose --- 15,21 ----
environment:
TZ: America/Sao_Paulo #optional - show logs in local timezone
GONIC_JUKEBOX_ENABLED: 'true'
+ GONIC_JUKEBOX_MPV_EXTRA_ARGS: "--log-file=/tmp/mpv_logs"
networks:
- proxy_network
# enable if you've enabled jukebox then compose up, and check the output of
? |
I get this error from docker when trying that exec: The full log from the container logs:
The container seems stuck on a restart loop with that log been repeated +/- every 1 minute. |
I just managed to time the exec command between the restarts, |
hmm i tried to spin up my old raspberry pi vm but it doesn't want to start. can you try another thing? how about putting the logs in a folder mounted to your host so that we can read them. and also don't restart in a loop --- 4,10 ----
gonic:
container_name: gonic
image: sentriz/gonic
- restart: unless-stopped
+ restart: "no"
ports:
- "4040:80"
volumes:
--- 12,23 ----
- '/media/music:/music:ro' # music
- '/media/podcasts:/podcasts:ro' # podcasts
- '/tmp/cache:/cache' # transcode cache dir
+ - '/tmp/gonic:/tmp/gonic'
environment:
TZ: America/Sao_Paulo #optional - show logs in local timezone
GONIC_JUKEBOX_ENABLED: 'true'
+ GONIC_JUKEBOX_MPV_EXTRA_ARGS: "--log-file=/tmp/gonic/mpv_logs"
networks:
- proxy_network after compose upping that, hopefully you should see some logs in /tmp/gonic/mpv_logs on your host system |
Still no logs, I would guess that mpv might not even be starting for me. Edit: Should we move this to an issue? |
good idea, i made #265 i'll have a look into some debug logging shortly |
So.. I tried running gonic (tag:latest) via Podman under Debian 11 (x64) and encountered the
Looking inside the /tmp directory, there's no /gonic/mpv_logs file. Actially there's no /gonic directory. Only two directories, /gonic-jukebox-3754582045 and /pulse-YrdcuDG02b3O.
|
hm maybe mpv doesn't like the non existing directory for the log file. can you try --log-file=/tmp/mpvlog or something, and see if it's created? |
Thanks for the tip! I can now see the mpv log. This is gonic log after starting the container:
And this is part (its a long one) of my /tmp/mpvlog
Not sure if it's my audio device.. How do I check? Tools like 'aplay' or 'speaker-test' arent available inside the container.
A permissions issue maybe? xof user (which the container runs as) was added to the 'audio' group.
|
More info:
And here's the output of the same command outside the container:
|
hmm i'm not sure. maybe it's a podman thing. does podman have a --privileged flag? or does that default the purpose of podman and are you able to run the audio example from here? just for testing |
Yes the --privileged flag is supported. I tried it but it didn't work. I ditched the whole podman rootless thing and decided to run the container as root and things worked! Looks like to access devices on the system, root is needed.
So I can confirm that sound is working on the server, with volume control!
Thanks @sentriz |
This might be helpful to others. I wasn't getting any audio from jukebox mode until I added an extra argument for mpv.
The error I was getting when trying to play files using mpv in the container:
|
related #125
related #106
related #164
todo