Skip to content
Snippets Groups Projects
Commit 7fd70146 authored by Chris Pastl's avatar Chris Pastl
Browse files

refactor: adapt make and dockerfile, add pulse test

parent 2d4602c1
No related branches found
No related tags found
No related merge requests found
Pipeline #5961 passed
......@@ -12,7 +12,15 @@ RUN apt update --allow-releaseinfo-change && \
apt -y --no-install-recommends install \
build-essential \
alsa-utils \
libssl-dev
libssl-dev \
espeak \
vorbis-tools \
sox \
libasound2 \
libasound2-plugins \
pulseaudio \
pulseaudio-utils
# Setup Engine
ENV TZ=Europe/Vienna
......@@ -26,7 +34,9 @@ COPY VERSION /srv/VERSION
RUN groupadd --gid ${AURA_GID} aura && \
useradd --gid ${AURA_GID} --no-user-group --uid ${AURA_UID} --home-dir /srv --no-create-home aura && \
chown -R ${AURA_UID}:${AURA_GID} /srv /var/audio
chown -R ${AURA_UID}:${AURA_GID} /srv /var/audio && \
usermod -aG audio,pulse,pulse-access aura && \
chown -R aura:aura $HOME
USER aura
......
......@@ -24,6 +24,7 @@ help::
# Settings
AURA_ENGINE_CORE_ALSA_CONFIG := ${CURDIR}/config/asound.conf
AURA_ENGINE_CORE_PULSE_CONFIG := ${CURDIR}/config/pulse
AURA_ENGINE_CORE_SOCKET := "aura_engine_socket"
AURA_ENGINE_CORE_CONFIG := ${CURDIR}/config/engine-core.docker.ini
AURA_AUDIO_STORE_SOURCE := ${CURDIR}/audio/source
......@@ -37,10 +38,11 @@ DOCKER_RUN = @docker run \
--name $(APP_NAME) \
--network="host" \
--mount type=tmpfs,destination=/tmp \
--device /dev/snd \
--group-add audio \
--ulimit rtprio=95 --ulimit memlock=-1 --shm-size=512m \
--env-file docker.env \
-e PULSE_SERVER=host.docker.internal \
--mount type=bind,source=/Users/chris/.config/pulse,target=/home/pulseaudio/.config/pulse \
-v "$(AURA_ENGINE_CORE_ALSA_CONFIG)":"/etc/asound.conf" \
-v "$(AURA_ENGINE_CORE_SOCKET)":"/srv/socket" \
-v "$(AURA_ENGINE_CORE_CONFIG)":"/etc/aura/engine-core.ini":ro \
......
......@@ -61,7 +61,7 @@ fallback_music_folder="/var/audio/fallback"
#
# Choose your weapon: "alsa" (1 input/output), "pulseaudio" (multi input/output)
# or "jack" (multi input/output)
soundsystem="alsa"
soundsystem="pulseaudio"
##################################################################################################
# Input / Output
......
#!/bin/bash
# Run some commands for testing - rm if done...
#
docker run -it -e PULSE_SERVER=host.docker.internal --mount type=bind,source=/Users/chris/.config/pulse,target=/home/pulseaudio/.config/pulse --entrypoint speaker-test --rm jess/pulseaudio -c 2 -l 1 -t wav
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment