0

I am trying to install docker on MacBookPro M1, I used this command to install docker:

brew install docker

Then, I run this command, to confirm the docker is installed:

docker --version

Output:

Docker version 24.0.2, build cb74dfcd85

Then, when I tried to run the following command :

docker run --pull always -itv "$(pwd)":/output oegdataintegration/gtfs-bench

I got this error:

docker: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?.

I tried to run different commands to check the status of docker, but all end with errors.

1- the brew services:

$ brew services start docker
Error: Formula `docker` has not implemented #plist, #service or installed a locatable service file

2- launchctl:

 $sudo launchctl status docker
    Password:
    Unrecognized subcommand: status
    Usage: launchctl <subcommand> ... | help [subcommand]
    Many subcommands take a target specifier that refers to a domain or service
    within that domain. The available specifier forms are:
    
    system/[service-name]
    Targets the system-wide domain or service within. Root privileges are required
    to make modifications.

3- systemctl:

$ sudo systemctl status docker
sudo: systemctl: command not found

Could anyone assist me how could I run the docker command without any errors?

  • The docker brew formula only includes docker client. You'll also need to configure docker engine: [Cannot connect to the Docker daemon on macOS](https://stackoverflow.com/questions/44084846/cannot-connect-to-the-docker-daemon-on-macos) – kangasta Jul 05 '23 at 21:21
  • @kangasta I tried the command in the link you sent. `brew install --cask docker` it shows this error: `Error: It seems there is already a Binary at '/usr/local/bin/docker'. ` – نظام الارشاد الطلابي Jul 06 '23 at 12:20
  • Did you remove the docker installed by `brew install docker` with `brew remove docker` before trying to install again with `--cask`? – kangasta Jul 06 '23 at 21:22

0 Answers0