on the Ubuntu 18.04 system I have cloned a project and to run it needs gradle
but at running the gradle command gradle swiplRun
I get the following error
Task :dockerRun FAILED docker: Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Post http://%2Fvar%2Frun%2Fdocker.sock/v1.39/containers/create?name=swiprolog: dial unix /var/run/docker.sock: connect: permission denied. See 'docker run --help'.
Task :dockerRunStatus FAILED Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/v1.39/containers/swiprolog/json: dial unix /var/run/docker.sock: connect: permission denied
FAILURE: Build completed with 2 failures.
to solve I tried
$ sudo groupadd docker
$ sudo usermod -a -G docker myname
"and once with"
$ sudo gpasswd -a myname docker
so I can run docker commands without sudo, but the same error
also ./gradlew --stop
and logout/login and reboot did not work too.
is it because of Docker or Gradle?
docker
group assigned after all. It didn't work for us for some reason at first, only after we installed Docker according to the documentation mentioned above. – Igor Nikolaev