I have installed docker using brew install homebrew/cask/docker
and varying other ways yet when I enter docker --version
to check CLI this error pops up
"-bash: /opt/homebrew/bin/docker: No such file or directory"
What should I be doing differently?
I have tried both installing through a .dmg
file as well as through homebrew using cask
.
CodePudding user response:
You can remove the installation and run these commands:
rm -rf ~/Library/Group\ Containers/group.com.docker
rm -rf ~/Library/Containers/com.docker.docker
rm -rf ~/.docker
Then try to install docker again and it should work. The .docker
directory must have been owned by the root user.