Skip to content

Commit 4426ed8

Browse files
netaskdsaghul
authored andcommitted
jibri: fix case when /dev/snd is not bound (jitsi#240 (comment))
1 parent 125775a commit 4426ed8

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

jibri/rootfs/etc/cont-init.d/10-config

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,12 @@ fi
2626
&& ( echo -e "\e[31mERROR: Please load snd-aloop module on the docker host.\e[39m"; kill 1; exit 1 )
2727

2828
# get host's audio group id
29-
host_audio_group="$(stat -c %g /dev/snd/pcmC0D0p)"
29+
host_audio_group="$(stat -c %g /dev/snd/pcmC0D0p 2>/dev/null)"
30+
31+
# audio group is not found. Has it been run without jibri.yml?
32+
[ -z "${host_audio_group}" ] \
33+
&& ( echo -e "\e[31mERROR: Binding /dev/snd is not found. Please check that you run docker-compose with -f jibri.yml.\e[39m"; kill 1; exit 1 )
34+
3035
# try to create group with this id. If group with the id already exists, just skip
3136
groupadd -g ${host_audio_group} jibri-audio >/dev/null 2>&1
3237
# include user to the group by id

0 commit comments

Comments
 (0)