Added script to run a shell in the container.

This commit is contained in:
Salvador E. Tropea 2020-10-06 17:55:00 -03:00
parent 8ab7deca80
commit 0475d2562b
1 changed files with 13 additions and 0 deletions

13
run_shell_same_user.sh Executable file
View File

@ -0,0 +1,13 @@
#!/bin/sh
export USER_ID=$(id -u)
export GROUP_ID=$(id -g)
docker run --rm -it -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \
--user $USER_ID:$GROUP_ID \
--env NO_AT_BRIDGE=1 \
--workdir="/home/$USER" \
--volume="/etc/group:/etc/group:ro" \
--volume="/home/$USER:/home/$USER:rw" \
--volume="/etc/passwd:/etc/passwd:ro" \
--volume="/etc/shadow:/etc/shadow:ro" \
--volume="/home/$USER:/home/$USER:rw" \
setsoft/kicad_auto:latest /bin/bash