Yes! Finally got the playout running using pipewire and Focusrite Scarlet 2x2; but not yet via docker.
Here's what I tried so far (after installing pipewire and related libs):
Pulled latest version of aura from main branch and configured according to manual. While Docker reported some issues with root privileges (even running with sudo - haven't we fixed that already?), running it locally threw some errors regarding the configuration class (which is still the old '.ini'-approach and should work, right?)
So switched directly to engire-core project and tried to run locally - which succeeded - fallback audio started playing - using "default" and as well as "pipewire".
Let's discuss any details and further steps in our upcoming meeting - I'll add some additional infos in the meantime...
It might be easier for you if you check out the alpha2 tag, not the main branch. That way we can be sure that both of us are running the same version and nothing else is interfering.
The root privileges are most likely tied to the log files. Are you sure that the aura user has read and write access to the logs directory and its sub-directories? We prevent these "root owned directories" by creating them during the Deployment Preparations steps, maybe try to run them again if you forgot them.
This sounds interesting, so even without running engine-core in docker you get audio latency issues? If that is the case we have to start investigating at the lowest level. Are you sure that no other soundserver then pipewire is running? Pulseaudio is often the
culprit. Can you include your config files please? Can you also include the output of the following command where hw:CARD=Plus,DEV=0 is your soundcard.
arecord -D"hw:CARD=Plus,DEV=0"--dump-hw-params
Here is my docker compose configuration when running aura-playout:
docker-compose.yml
version:"3.4"services:engine-api:container_name:engine-apiimage:autoradio/engine-api:${AURA_ENGINE_API_VERSION}user:"2872:2872"environment:TZ:${TIMEZONE}AURA_ENGINE_API_LOG_LEVEL:${AURA_ENGINE_API_LOG_LEVEL}AURA_ENGINE_API_HOST:0.0.0.0AURA_ENGINE_API_PORT:8008AURA_ENGINE_API_DB_HOST:"engine-api-postgres"AURA_ENGINE_API_DB_NAME:${AURA_ENGINE_API_DB_NAME:?name of the database for engine-api}AURA_ENGINE_API_DB_USER:${AURA_ENGINE_API_DB_USER:?database user for engine-api DB}AURA_ENGINE_API_DB_PASS:${AURA_ENGINE_API_DB_PASS:?password for engine-api DB}volumes:-./../services/:/etc/aura/:ro-${AURA_LOGS}:/srv/logsdepends_on:engine-api-postgres:condition:service_healthyports:-"${AURA_ENGINE_API_BIND_URL:-127.0.0.1:8008}:8008"networks:-auranet-internal-engine-apihealthcheck:test:["CMD","nc","-z","-w","3","localhost","8008"]engine-api-postgres:image:postgres:${POSTGRES_VERSION:-14}restart:alwaysenvironment:TZ:${TIMEZONE}POSTGRES_DB:${AURA_ENGINE_API_DB_NAME:?name of the database for engine-api}POSTGRES_USER:${AURA_ENGINE_API_DB_USER:?database user for engine-api DB}POSTGRES_PASSWORD:${AURA_ENGINE_API_DB_PASS:?password for engine-api DB}volumes:-engine_api_db_data:/var/lib/postgresql/dataexpose:-"5432"networks:-internal-engine-apihealthcheck:test:["CMD","pg_isready","-U","${AURA_ENGINE_API_DB_USER:?databaseuserforengine-apiDB}","-d","${AURA_ENGINE_API_DB_NAME:?nameofthedatabaseforengine-api}"]engine-core:container_name:engine-coreimage:autoradio/engine-core:${AURA_ENGINE_CORE_VERSION}user:"2872:2872"group_add:-audiodevices:-/dev/sndenvironment:TZ:${TIMEZONE}AURA_ENGINE_CORE_LOG_LEVEL:${AURA_ENGINE_CORE_LOG_LEVEL:?value from 1-5}AURA_ENGINE_RUN_AS_ROOT:false# Audio Device SettingsAURA_ENGINE_OUTPUT_DEVICE:${AURA_ENGINE_OUTPUT_DEVICE}AURA_ENGINE_INPUT_DEVICE:${AURA_ENGINE_INPUT_DEVICE}# Fallback SettingsAURA_ENGINE_FALLBACK_SHOW_NAME:${AURA_ENGINE_FALLBACK_SHOW_NAME}AURA_ENGINE_FALLBACK_SHOW_ID:${AURA_ENGINE_FALLBACK_SHOW_ID}AURA_ENGINE_FALLBACK_TYPE:${AURA_ENGINE_FALLBACK_TYPE}AURA_ENGINE_FALLBACK_FOLDER_RELOAD:${AURA_ENGINE_FALLBACK_FOLDER_RELOAD}AURA_ENGINE_FALLBACK_MAX_BLANK:${AURA_ENGINE_FALLBACK_MAX_BLANK}AURA_ENGINE_FALLBACK_MIN_NOISE:${AURA_ENGINE_FALLBACK_MIN_NOISE}AURA_ENGINE_FALLBACK_THRESHOLD:${AURA_ENGINE_FALLBACK_THRESHOLD}# Misc SettingsAURA_ENGINE_FRAME_SAMPLERATE:${AURA_ENGINE_FRAME_SAMPLERATE}AURA_ENGINE_FRAME_DURATION:${AURA_ENGINE_FRAME_DURATION}AURA_ENGINE_FRAME_SIZE:${AURA_ENGINE_FRAME_SIZE}AURA_ENGINE_API_URL_PLAYLOG:${AURA_ENGINE_API_URL_PLAYLOG}# Server SettingsAURA_ENGINE_SERVER_TIMEOUT:${AURA_ENGINE_SERVER_TIMEOUT}AURA_ENGINE_TELNET_ENABLE:${AURA_ENGINE_TELNET_ENABLE}AURA_ENGINE_TELNET_HOST:${AURA_ENGINE_TELNET_HOST}AURA_ENGINE_TELNET_PORT:${AURA_ENGINE_TELNET_PORT}# Stream Input SettingsAURA_ENGINE_STREAM_INPUT_MAX_BUFFER:${AURA_ENGINE_STREAM_INPUT_MAX_BUFFER}AURA_ENGINE_STREAM_INPUT_TIMEOUT:${AURA_ENGINE_STREAM_INPUT_TIMEOUT}# Stream Output SettingsAURA_ENGINE_STREAM_OUTPUT_ENABLE:${AURA_ENGINE_STREAM_OUTPUT_ENABLE}AURA_ENGINE_STREAM_OUTPUT_ENCODING:${AURA_ENGINE_STREAM_OUTPUT_ENCODING}AURA_ENGINE_STREAM_OUTPUT_BITRATE:${AURA_ENGINE_STREAM_OUTPUT_BITRATE}AURA_ENGINE_STREAM_OUTPUT_CHANNELS:${AURA_ENGINE_STREAM_OUTPUT_CHANNELS}AURA_ENGINE_STREAM_OUTPUT_HOST:${AURA_ENGINE_STREAM_OUTPUT_HOST}AURA_ENGINE_STREAM_OUTPUT_PORT:${AURA_ENGINE_STREAM_OUTPUT_PORT}AURA_ENGINE_STREAM_OUTPUT_USER:${AURA_ENGINE_STREAM_OUTPUT_USER}AURA_ENGINE_STREAM_OUTPUT_PASSWORD:${AURA_ENGINE_STREAM_OUTPUT_PASSWORD}AURA_ENGINE_STREAM_OUTPUT_MOUNTPOINT:${AURA_ENGINE_STREAM_OUTPUT_MOUNTPOINT}AURA_ENGINE_STREAM_OUTPUT_NAME:${AURA_ENGINE_STREAM_OUTPUT_NAME}AURA_ENGINE_STREAM_OUTPUT_URL:${AURA_ENGINE_STREAM_OUTPUT_URL}AURA_ENGINE_STREAM_OUTPUT_DESCRIPTION:${AURA_ENGINE_STREAM_OUTPUT_DESCRIPTION}AURA_ENGINE_STREAM_OUTPUT_GENRE:${AURA_ENGINE_STREAM_OUTPUT_GENRE}volumes:-./../services/:/etc/aura/:ro-./asound.conf:/etc/asound.conf-${AURA_AUDIO_STORE_SOURCE}:/var/audio/source-${AURA_AUDIO_STORE_PLAYLIST}:/var/audio/playlist-${AURA_AUDIO_STORE_FALLBACK}:/var/audio/fallback-${AURA_LOGS}:/srv/logs-aura_engine_socket:/srv/sockettmpfs:-/tmpports:-1234:1234networks:-auranetengine:container_name:engineimage:autoradio/engine:${AURA_ENGINE_VERSION}user:"2872:2872"environment:TZ:${TIMEZONE}AURA_ENGINE_LOG_LEVEL:${AURA_ENGINE_LOG_LEVEL}# Database for caching scheduling dataAURA_ENGINE_DB_HOST:${AURA_ENGINE_DB_HOST}AURA_ENGINE_DB_NAME:${AURA_ENGINE_DB_NAME:?name of the database for engine}AURA_ENGINE_DB_USER:${AURA_ENGINE_DB_USER:?database user for engine DB}AURA_ENGINE_DB_PASS:${AURA_ENGINE_DB_PASS:?password for engine DB}# APIAURA_ENGINE_API_BASE_URL:${AURA_ENGINE_API_BASE_URL}AURA_STEERING_BASE_URL:${AURA_STEERING_BASE_URL}AURA_TANK_BASE_URL:${AURA_TANK_BASE_URL}AURA_TANK_ENGINE_USER:engineAURA_TANK_ENGINE_PASSWORD:${AURA_TANK_ENGINE_PASSWORD:?secret of engine to connect to tank}# Details for the Station Fallback i.e. the default show when nothing is scheduledAURA_ENGINE_FALLBACK_SHOW_NAME:${AURA_ENGINE_FALLBACK_SHOW_NAME}AURA_ENGINE_FALLBACK_SHOW_ID:${AURA_ENGINE_FALLBACK_SHOW_ID}# Offset in seconds how long it takes for Liquidsoap to actually execute a scheduler command; Crucial to keep things in syncAURA_ENGINE_LATENCY_OFFSET:${AURA_ENGINE_LATENCY_OFFSET}# Fade duration when selecting another mixer input (seconds)AURA_ENGINE_FADE_IN_TIME:${AURA_ENGINE_FADE_IN_TIME}AURA_ENGINE_FADE_OUT_TIME:${AURA_ENGINE_FADE_OUT_TIME}# Host and UDP port where heartbeat is sent to (disabled if empty string)# Seconds how often the vitality of Engine Core should be checked (default=1)AURA_ENGINE_HEARTBEAT_SERVER:${AURA_ENGINE_HEARTBEAT_SERVER}AURA_ENGINE_HEARTBEAT_SERVER_PORT:${AURA_ENGINE_HEARTBEAT_SERVER_PORT}AURA_ENGINE_HEARTBEAT_FREQUENCY:${AURA_ENGINE_HEARTBEAT_FREQUENCY}volumes:-./../services/:/etc/aura/:ro-${AURA_AUDIO_STORE_SOURCE}:/var/audio/source:ro-${AURA_AUDIO_STORE_PLAYLIST}:/var/audio/playlist-${AURA_LOGS}:/srv/logs-aura_engine_socket:/srv/socketdepends_on:-engine-postgres-engine-api-engine-corenetworks:-auranet-internal-engineengine-postgres:image:postgres:${POSTGRES_VERSION:-14}restart:alwaysenvironment:TZ:${TIMEZONE}POSTGRES_PASSWORD:${AURA_ENGINE_DB_PASS:?password for engine DB}POSTGRES_USER:${AURA_ENGINE_DB_USER:?database user for engine DB}POSTGRES_DB:${AURA_ENGINE_DB_NAME:?name of the database for engine}volumes:-engine_db_data:/var/lib/postgresql/datanetworks:-internal-engineengine-recorder:container_name:engine-recorderimage:autoradio/engine-recorder:${AURA_ENGINE_RECORDER_VERSION:-unstable}environment:AUDIO_DEVICE:${AURA_ENGINE_RECORDER_AUDIO_DEVICE:-pcm.aura_recorder}SAMPLE_FORMAT:${AURA_ENGINE_RECORDER_SAMPLE_FORMAT}SAMPLE_RATE:${AURA_ENGINE_RECORDER_SAMPLE_RATE}SEGMENT_LENGTH:${AURA_ENGINE_RECORDER_SEGMENT_LENGTH:-1800}SEGMENT_STRING_FORMAT:${AURA_ENGINE_RECORDER_SEGMENT_STRING_FORMAT:-%Y-%m-%d_%H:%M:%S}SYNC:${AURA_ENGINE_RECORDER_SYNC:-False}SYNC_DESTINATION:${AURA_ENGINE_RECORDER_SYNC_DESTINATION:-/tmp}SYNC_OPTIONS:${AURA_ENGINE_RECORDER_SYNC_OPTIONS:--a}DELETE:${AURA_ENGINE_RECORDER_DELETE:-False}DELETE_OLDER_THAN:${AURA_ENGINE_RECORDER_DELETE_OLDER_THAN:-7}LOG_LEVEL:${AURA_ENGINE_RECORDER_LOG_LEVEL:-INFO}volumes:-./../services/:/etc/aura/:ro-./asound.conf:/etc/asound.conf-${AURA_AUDIO_STORE_RECORDINGS}:/var/audio-${AURA_LOGS}:/srv/loggroup_add:-audiodevices:-/dev/snd:/dev/sndprofiles:-engine-recorder-enablednetworks:auranet:name:auranetinternal-engine:internal-engine-api:volumes:aura_engine_socket:engine_db_data:engine_api_db_data:
# Released versions of the Docker imagesAURA_ENGINE_VERSION=1.0.0-alpha2AURA_ENGINE_API_VERSION=1.0.0-alpha2AURA_ENGINE_CORE_VERSION=1.0.0-alpha2AURA_ENGINE_RECORDER_VERSION=1.0.0-alpha2# Version of postgres. Defaults to 14# POSTGRES_VERSION=14### GENERAL# TimezoneTIMEZONE=Europe/Vienna# Folder to store service log filesAURA_LOGS=../../logs### AUDIO STORE# Folder holding audio sources provided by Tank (absolute path)AURA_AUDIO_STORE_SOURCE=../../audio/source# Folder holding M3U PlaylistsAURA_AUDIO_STORE_PLAYLIST=../../audio/playlist# Folder holding audio for fallback scenariosAURA_AUDIO_STORE_FALLBACK=../../audio/fallback# Folder holding recordingsAURA_AUDIO_STORE_RECORDINGS=../../audio/recordings### ENGINE# Possible values: debug, info, warning, error, criticalAURA_ENGINE_LOG_LEVEL=info# Database for caching scheduling dataAURA_ENGINE_DB_HOST=engine-postgresAURA_ENGINE_DB_NAME=aura_engineAURA_ENGINE_DB_USER=aura_engineAURA_ENGINE_DB_PASS=Some_Password# APIAURA_ENGINE_API_BASE_URL=http://engine-api:8008/AURA_STEERING_BASE_URL=http://steering:8000/AURA_TANK_BASE_URL=http://tank:8040/AURA_TANK_ENGINE_PASSWORD=Some_Password# Offset in seconds how long it takes for Liquidsoap to actually execute a scheduler command; Crucial to keep things in syncAURA_ENGINE_LATENCY_OFFSET=0.5# Fade duration when selecting another mixer input (seconds)AURA_ENGINE_FADE_IN_TIME=0.1AURA_ENGINE_FADE_OUT_TIME=0.1# Host and UDP port where heartbeat is sent to (disabled if empty string)# Seconds how often the vitality of Engine Core should be checked (default=1)AURA_ENGINE_HEARTBEAT_SERVER=AURA_ENGINE_HEARTBEAT_SERVER_PORT=43334AURA_ENGINE_HEARTBEAT_FREQUENCY=1### ENGINE API# Possible values: debug, info, warning, error, criticalAURA_ENGINE_API_LOG_LEVEL=info# Configure the database for engine-apiAURA_ENGINE_API_DB_NAME=aura_engine_apiAURA_ENGINE_API_DB_USER=aura_engine_apiAURA_ENGINE_API_DB_PASS=Some_Password# Set the URL engine-api should bind to. Note that setting this to 0.0.0.0:8008 would make engine-api globally accessible. You probably want to set this to a private network.# AURA_ENGINE_API_BIND_URL=127.0.0.1:8008### ENGINE CORE# Audio Device SettingsAURA_ENGINE_OUTPUT_DEVICE=pcm.aura_engineAURA_ENGINE_INPUT_DEVICE=pcm.aura_engine# Fallback SettingsAURA_ENGINE_FALLBACK_SHOW_NAME=Station FallbackAURA_ENGINE_FALLBACK_SHOW_ID=-1AURA_ENGINE_FALLBACK_TYPE=folderAURA_ENGINE_FALLBACK_FOLDER_RELOAD=300AURA_ENGINE_FALLBACK_MAX_BLANK=15.AURA_ENGINE_FALLBACK_MIN_NOISE=0.AURA_ENGINE_FALLBACK_THRESHOLD=-80.# Misc SettingsAURA_ENGINE_CORE_LOG_LEVEL=3AURA_ENGINE_FRAME_SAMPLERATE=AURA_ENGINE_FRAME_DURATION=AURA_ENGINE_FRAME_SIZE=64AURA_ENGINE_API_URL_PLAYLOG=http://engine-api:8008/api/v1/playlog# Server SettingsAURA_ENGINE_SERVER_TIMEOUT=16380AURA_ENGINE_TELNET_ENABLE=trueAURA_ENGINE_TELNET_HOST=0.0.0.0AURA_ENGINE_TELNET_PORT=1234# Stream Input SettingsAURA_ENGINE_STREAM_INPUT_MAX_BUFFER=5.0AURA_ENGINE_STREAM_INPUT_TIMEOUT=10.0# Stream Output SettingsAURA_ENGINE_STREAM_OUTPUT_ENABLE=falseAURA_ENGINE_STREAM_OUTPUT_ENCODING=oggAURA_ENGINE_STREAM_OUTPUT_BITRATE=128AURA_ENGINE_STREAM_OUTPUT_CHANNELS=2AURA_ENGINE_STREAM_OUTPUT_HOST=localhostAURA_ENGINE_STREAM_OUTPUT_PORT=8888AURA_ENGINE_STREAM_OUTPUT_USER=sourceAURA_ENGINE_STREAM_OUTPUT_PASSWORD=sourceAURA_ENGINE_STREAM_OUTPUT_MOUNTPOINT=aura-radio.oggAURA_ENGINE_STREAM_OUTPUT_NAME=AURA.radioAURA_ENGINE_STREAM_OUTPUT_URL=https://aura.radioAURA_ENGINE_STREAM_OUTPUT_DESCRIPTION=Music from the community radio software suiteAURA_ENGINE_STREAM_OUTPUT_GENRE=music### ENGINE RECORDER# Set an ALSA audio device or HTTP audio streamAURA_ENGINE_RECORDER_AUDIO_DEVICE=pcm.aura_recorder# audio codec format, for example "pcm_s32le"AURA_ENGINE_RECORDER_SAMPLE_FORMAT=# sampling rate, for example 44100AURA_ENGINE_RECORDER_SAMPLE_RATE=# time length of one recording block in seconds, for example 1800AURA_ENGINE_RECORDER_SEGMENT_LENGTH=1800# name of the segment, for example "%Y-%m-%d_%H:%M:%S_%s"AURA_ENGINE_RECORDER_SEGMENT_STRING_FORMAT=%Y-%m-%d_%H:%M:%S# set to true if you want to sync the content of AURA_AUDIO_STORE/recordings/block to somewhere elseAURA_ENGINE_RECORDER_SYNC=False# the destination where we sync to, this can be a remote location. If you chose a remote location# make sure that you supply a sshkey, otherwise the script will ask you for your password every# day# for example user@remote_server:/tmp/audio# AURA_ENGINE_RECORDER_SYNC_DESTINATION=/tmp# the options with which we start rsync. They are not allowed to have spaces in between them# for example "-a" or "-apogt"# AURA_ENGINE_RECORDER_SYNC_OPTIONS=-a# set to True if you want to delete audio files older than X daysAURA_ENGINE_RECORDER_DELETE=False# AURA_ENGINE_RECORDER_DELETE_OLDER_THAN=7AURA_ENGINE_RECORDER_LOG_LEVEL=INFO### DEVELOPMENT #### If you want to use a dev-setup, which exposes some more ports# and builds the containers locally, uncomment the following# line# COMPOSE_FILE=docker-compose.yml:docker-compose.dev.yml
Encountered no severe problems while listening to the music coming from my personal audio interface - routed through the aura-testing-setup - while running engine-core in a docker container and enabling line-in.
Also noticed fallback audio after muting input signal
So closing this ticket - let's discuss further issues in #55 (closed).
I am reopening this since we neglected some of the tasks mentioned above. We still need to
Decide in the team if we should support ALSA with PipeWire only
Add the instructions to the Engine Core README
Add the instructions to the "Aura Playout" docs at docs.aura.radio
As I mentioned here in #50 (closed), I am in favor of support PipeWire only (but with JACK, not ALSA). I created a feature branch where I started to include the instructions to the Engine Core README. @chrizz are you okay with me reassigning the ticket to myself?
No matter what we choose, ALSA or JACK, the PipeWire instructions can be reused.
IMHO we can set PipeWire + ALSA as a default requirement, since PipeWire is the default sound server in Debian 12 / Gnome.
We only need to add the requirement, that we officially only support Debian 12+. As a consequence the install instructions can also be much shorter and more clean.
Regarding JACK vs. ALSA I cannot comment, because I need more insights first. I was unter the impression, that PipeWire already supports multi-channel handling natively.
I don't prefer any of these methods yet but I'm happy that my setup works using ALSA - at least for now.
@Loxbie How can I switch my current ALSA-only-setup to use JACK? I noticed the change in the docker file but are there any additional configurations neccessary which I'm not aware of?
We could discuss it next Thu before/after our retro meeting or in the upcoming days afternoon if you prefer.
There is some stuff happening when building the container, manly swapping the base container image from liquidsoap to debian (for better PipeWire support), installing pipewire and pipewire-jack.
But this all happens in the container. On your host system you would have to install PipeWire as the sound server and optionally a ui like qpwgraph to connect your in- and outputs. I am still working on the complete documentation but I can walk you through it if you want to test it right away.
Thursday before the retro sounds great, lets fix the details in the matrix chat.