diff --git a/Dockerfile b/Dockerfile index b7ee71b..6be94c8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -34,7 +34,7 @@ RUN sudo apt-get update -qq && sudo apt-get install -qqy \ RUN curl -sSL https://get.docker.com/ | sh # Define additional metadata for our image. VOLUME /var/lib/docker -RUN sudo usermod -aG docker docker +#RUN sudo usermod -aG docker docker #Finishing Installing Docker # install python and the packages the your code depends on along with jq so we can parse JSON diff --git a/README.md b/README.md index 61c07c9..42ce0df 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,3 @@ # Docker Github Action Runner -## Version 1.0.11 \ No newline at end of file +## Version 1.0.12 \ No newline at end of file diff --git a/wrapdocker.sh b/wrapdocker.sh index dff6a25..f7afa69 100644 --- a/wrapdocker.sh +++ b/wrapdocker.sh @@ -1,5 +1,9 @@ #!/bin/bash +if [[ -z "${HOME_USER}" ]]; then + HOME_USER="docker" +fi + # Ensure that all nodes in /dev/mapper correspond to mapped devices currently loaded by the device-mapper kernel driver dmsetup mknodes @@ -108,6 +112,8 @@ else fi sleep 1 done + sudo chmod -R a+rwX /var/run/docker.sock + sudo su - ${HOME_USER} -c "sudo usermod -aG docker ${HOME_USER}" [[ $1 ]] && exec "$@" exec bash --login fi \ No newline at end of file