title: Got permission denied while trying to connect to the Docker daemon socket
body: <p>I'm trying to run a simple build on teamcity with docker on windows and use powershell for my commands. On teamcity I'm logged in as a super user and this build uses the command line to show the docker version. When I run this build I get this error message:</p>
  <pre><code>[15:30:55]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.40/version: dial unix /var/run/docker.sock: connect: permission denied
  [15:30:55]Process exited with code 1
  </code></pre>
  <p>I'm using the following docker-compose file:</p>
  <pre><code>version: '3.1'
  
  services:
    teamcity:
      image: jetbrains/teamcity-server
      volumes:
        - teamcity-server-datadir:/data/teamcity_server/datadir
        - teamcity-server-logs:/opt/teamcity/logs
      ports:
        - 8111:8111
    teamcity-agent:
      image: jetbrains/teamcity-agent
      environment:
        SERVER_URL: http://teamcity:8111
      volumes:
        - /var/run/docker.sock:/var/run/docker.sock
  volumes:
    teamcity-server-datadir:
    teamcity-server-logs:
  </code></pre>
  <p>I have tried the workaround to add a group user with the sudo commands, but sudo is not recognized.
  Any help is welcome!</p>