You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With a new Pulseaudio server (I'm currently running 13.99, but I understand this applies for version 12 and above), having the cookie is no longer sufficient to allow the Pulseaudio clients to connect.
I've worked around the problem with the same technique as described in the x11docker issue #71 - creating an anonymous one-use pulseaudio socket and mounting it instead of the primary socket.
My run script looks something like this:
DOCKERID=${RANDOM} # or some other value that makes sense, for example - a counter
pasocket=$(pactl load-module module-native-protocol-unix socket=$HOME/.config/pulse/docker-socket$DOCKERID auth-anonymous=1)
docker run ... -v $HOME/.config/pulse/zoiper-socket$DOCKERID:/home/user/.pulse.socket ...
# after run
pactl unload-module $pasocket
rm -f $HOME/.config/pulse/zoiper-socket$DOCKERID
[ user is the user name of the unprivileged user inside docker]
The /etc/pulse/client.conf has to be updated, but that is not enough for command line utilities such as pacat - these need to also have the PULSE_SERVER environment variable set to unix:/home/user/.pulse.socket. I solved this by tacking an export at the end of /home/user/.bashrc. I check that this works well for the GUI applications I'm running in the docker.
The text was updated successfully, but these errors were encountered:
With a new Pulseaudio server (I'm currently running 13.99, but I understand this applies for version 12 and above), having the cookie is no longer sufficient to allow the Pulseaudio clients to connect.
I've worked around the problem with the same technique as described in the x11docker issue #71 - creating an anonymous one-use pulseaudio socket and mounting it instead of the primary socket.
My run script looks something like this:
[
user
is the user name of the unprivileged user inside docker]The
/etc/pulse/client.conf
has to be updated, but that is not enough for command line utilities such aspacat
- these need to also have thePULSE_SERVER
environment variable set tounix:/home/user/.pulse.socket
. I solved this by tacking anexport
at the end of/home/user/.bashrc
. I check that this works well for the GUI applications I'm running in the docker.The text was updated successfully, but these errors were encountered: