ERROR: Couldn't connect to Docker daemon at http+docker://localhost - is it running? Windows subsystem for Linux

From this github issue:

Try running dockerd or sudo dockerd if required first to start daemon. If you start dockerd with sudo you may want to run docker-compose up with sudo also. otherwise it's fine.


It turns out the issue was to do with the groups. The solution that I found worked was to remove the user group "docker" using:

sudo groupadd docker
sudo usermod -aG docker $(whoami)

Then I ran the command for my make file and it worked!

I hope this benefits some of you!