Skip to content

Commit

Permalink
Check existence when add host devices to container. (#487)
Browse files Browse the repository at this point in the history
  • Loading branch information
BlindingDark authored Aug 11, 2024
1 parent 657f3d4 commit 64d2a3e
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions telega-util.el
Original file line number Diff line number Diff line change
Expand Up @@ -2703,9 +2703,12 @@ Binds current symbol to SYM-BIND."
" --net=host"
;; Add host devices to container to allow voice/video
;; recording
" --device /dev/snd:/dev/snd"
" --device /dev/video0:/dev/video0"
" --device /dev/video1:/dev/video1"
(when (file-exists-p "/dev/snd")
" --device /dev/snd:/dev/snd")
(when (file-exists-p "/dev/video0")
" --device /dev/video0:/dev/video0")
(when (file-exists-p "/dev/video1")
" --device /dev/video1:/dev/video1")

;; Export resources for pulseaudio to work
;; ref: https://stackoverflow.com/questions/28985714/run-apps-using-audio-in-a-docker-container
Expand Down

0 comments on commit 64d2a3e

Please sign in to comment.