Sound in Container: https://github.com/mviereck/x11docker/wiki/Container-sound:-ALSA-or-Pulseaudio Create socket: ``` pactl load-module module-native-protocol-unix socket=/tmp/pulseaudio.socket ``` create `/tmp/pulseaudio.client.conf` with: ``` default-server = unix:/tmp/pulseaudio.socket # Prevent a server running in the container autospawn = no daemon-binary = /bin/true # Prevent the use of shared memory enable-shm = false ``` Share pulse stuff ``` docker run --rm \ --env PULSE_SERVER=unix:/tmp/pulseaudio.socket \ --env PULSE_COOKIE=/tmp/pulseaudio.cookie \ --volume /tmp/pulseaudio.socket:/tmp/pulseaudio.socket \ --volume /tmp/pulseaudio.client.conf:/etc/pulse/client.conf \ --user $(id -u):$(id -g) \ imagename ```