Skip to content
This repository has been archived by the owner on Mar 23, 2021. It is now read-only.

Commit

Permalink
chore(dockerfile): 更新启动项,使用参数--privileged支持容器访问主机硬件
Browse files Browse the repository at this point in the history
  • Loading branch information
zjZSTU committed Oct 11, 2019
1 parent aa06bad commit ebe6f8f
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
3 changes: 3 additions & 0 deletions dockerfiles/qq/qq.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,10 @@ function startup()
{
docker run \
--device=/dev/snd:/dev/snd \
--device=/dev/video0:/dev/video0 \
--privileged \
-v /tmp/.X11-unix:/tmp/.X11-unix \
--privileged \
-e DISPLAY=unix${DISPLAY} \
-e AUDIO_GID=`getent group audio | cut -d: -f3` \
-e VIDEO_GID=`getent group video | cut -d: -f3` \
Expand Down
2 changes: 2 additions & 0 deletions dockerfiles/thunder/thunder.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ function startup()
{
docker run \
--device=/dev/snd:/dev/snd \
--device=/dev/video0:/dev/video0 \
--privileged \
-v /tmp/.X11-unix:/tmp/.X11-unix \
-e DISPLAY=unix${DISPLAY} \
-e AUDIO_GID=`getent group audio | cut -d: -f3` \
Expand Down
2 changes: 2 additions & 0 deletions dockerfiles/wechat/wechat.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ function startup()
{
docker run \
--device=/dev/snd:/dev/snd \
--device=/dev/video0:/dev/video0 \
--privileged \
-v /tmp/.X11-unix:/tmp/.X11-unix \
-e DISPLAY=unix${DISPLAY} \
-e AUDIO_GID=`getent group audio | cut -d: -f3` \
Expand Down

0 comments on commit ebe6f8f

Please sign in to comment.