-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathDockerfile.template
40 lines (31 loc) · 1.03 KB
/
Dockerfile.template
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# --- Note on PulseAudio version ---
# Alpine 3.15 pins PulseAudio version to 15.x.x
# See https://pkgs.alpinelinux.org/packages?name=pulseaudio&branch=v3.15
ARG BALENA_ARCH=%%BALENA_ARCH%%
FROM balenalib/$BALENA_ARCH-alpine:3.15-run
WORKDIR /usr/src
# UDev is required to autodetect ALSA devices
# DBus is required for module-bluetooth-discover
ENV UDEV=on
ENV DBUS_SYSTEM_BUS_ADDRESS=unix:path=/host/run/dbus/system_bus_socket
# Install PulseAudio and dependencies
RUN install_packages \
alsa-utils \
mawk \
pulseaudio~=15 \
pulseaudio-alsa \
pulseaudio-bluez \
pulseaudio-utils \
xxd
# For local development
#dev-cmd-live=pulseaudio || balena-idle
# PulseAudio configuration
COPY pulseaudio/block.pa /etc/pulse/default.pa.d/00-audioblock.pa
COPY pulseaudio/client.conf /etc/pulse/client.conf
COPY pulseaudio/daemon.conf /etc/pulse/daemon.conf
# UDev configuration
COPY udev/95-balena-audio.rules /etc/udev/rules.d/95-balena-audio.rules
# Entrypoint
COPY entry.sh .
ENTRYPOINT [ "/bin/bash", "/usr/src/entry.sh" ]
CMD [ "pulseaudio" ]