Docker-Compose can't connect to Docker Daemon

后端 未结 18 1091
死守一世寂寞
死守一世寂寞 2020-12-22 20:25

I am getting an error message saying I can\'t connect to the docker daemon. I have looked into other people\'s answers who have had similar issues but it hasn\'t helped. I

18条回答
  •  眼角桃花
    2020-12-22 21:11

    Is there slight possibility you deleted default machine? But, first check if all files are there (OSX, similar on other systems)

    brew install docker docker-compose docker-machine xhyve docker-machine-driver-xhyve
    brew link docker docker-compose docker-machine xhyve docker-machine-driver-xhyve
    
    sudo chown root:wheel /usr/local/opt/docker-machine-driver-xhyve/bin/docker-machine-driver-xhyve
    sudo chmod u+s /usr/local/opt/docker-machine-driver-xhyve/bin/docker-machine-driver-xhyve
    

    Also, install Docker App, as it much easier to maintain containers:

    brew cask reinstall docker
    

    ans start Docker app from finder (wait until service is fully started)

    Then, check instalation with:

    docker-machine ls
    

    if no machines are present in list, create one and start it:

    docker-machine create default
    docker-machine start default
    

    After this, build, compose and all other commands should work properly.

提交回复
热议问题