shairport-sync
Dockerized version of shairport-sync.
Build
# Build version 2.8.1
docker build -t knapoc/shairport-sync .
# Build other version
docker build --build-arg SHAIRPORT_VERSION=2.8.0 --build-arg ALAC_VERSION= -t knapoc/shairport-sync:2.8.0 .
Run
docker run -d \
--name=container_name
--net=host \
--device=/dev/snd:/dev/snd \
-v "/path/to/your/shairport-sync.conf:/usr/local/etc/shairport-sync.conf" \
knapoc/shairport-sync
Compose
version: '2'
services:
shairportSync:
restart: always
image: knapoc/shairport-sync
network_mode: host
volumes:
- "/etc/localtime:/etc/localtime:ro"
- "/path/to/your/shairport-sync.conf:/usr/local/etc/shairport-sync.conf"
devices:
- "/dev/snd:/dev/snd"
Parameters
--net=host
must be run in host mode--device=/dev/snd:/dev/snd
share host alsa system with container. Does not require--privileged
as-v /dev/snd:/dev/snd
would-v "/path/to/your/shairport-sync.conf:/usr/local/etc/shairport-sync.conf"
(optional) - your own shairport-sync.conf file. A default config file is being copied during the build process.- shairport-sync compilation arguments:
--with-alsa
# output_backend--with-pipe
# optional output_backend to enable raw audio to be output through a unix pipe--with-avahi
# mdns_backend--with-ssl=openssl
# for encryption and related utilities--with-soxr
# for libsoxr-based resampling--with-metadata
# to add support for Shairport Sync to pipe metadata to a compatible application of your choice--with-apple-alac
# to include the Apple ALAC Decoder.