Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

macos-13-xlarge (i.e. Mac Arm Processor) Unable to Install and Start Docker #3012

Open
SachaTe opened this issue Nov 28, 2023 · 7 comments
Open
Labels
bug Something isn't working

Comments

@SachaTe
Copy link

SachaTe commented Nov 28, 2023

Describe the bug
We have been trying to install docker on the Mac Arm runner and have not been successful.

To Reproduce
Steps to reproduce the behavior:

jobs:
  build-and-test:
    runs-on: 'macos-13-xlarge'

    steps:
      - name: Docker Test
        run: |
          softwareupdate --install-rosetta --agree-to-license
          brew install --cask docker
          docker run hello-world

Expected behavior
Docker should run

Runner Version and Platform

0s
Current runner version: '2.3[1](https://github.com/hinge-health/cv-engine/actions/runs/7024641202/job/19113810137#step:1:1)1.0'
Operating System
  macOS
  13.6.1
  [2](https://github.com/hinge-health/cv-engine/actions/runs/7024641202/job/19113810137#step:1:2)2G[3](https://github.com/hinge-health/cv-engine/actions/runs/7024641202/job/19113810137#step:1:3)13
Runner Image
  Image: macos-13-arm6[4](https://github.com/hinge-health/cv-engine/actions/runs/7024641202/job/19113810137#step:1:4)
  Version: 2023111[5](https://github.com/hinge-health/cv-engine/actions/runs/7024641202/job/19113810137#step:1:5).2
  Included Software: https://github.com/actions/runner-images/blob/macOS-13/20231115.2/images/macos/macos-13-arm[6](https://github.com/hinge-health/cv-engine/actions/runs/7024641202/job/19113810137#step:1:7)4-Readme.md
  Image Release: https://github.com/actions/runner-images/releases/tag/macOS-13%2F20231115.2
Runner Image Provisioner
  2.0.321.1
GITHUB_TOKEN Permissions
  Actions: write
  Checks: write
  Contents: write
  Deployments: write
  Discussions: write
  Issues: write
  Metadata: read
  Packages: write
  Pages: write
  PullRequests: write
  RepositoryProjects: write
  SecurityEvents: write
  Statuses: write
Secret source: Actions
Prepare workflow directory
Prepare all required actions
Complete job name: build-and-test

What's not working?

We get error;

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

Runner and Worker's Diagnostic Logs

I have looked online and tried multiple steps which all fail. For example:

  1. Tried installing and starting colima
  2. Tried opening docker via open --background -a Docker but get error Unable to find application named 'Docker'
  3. When I run /Applications/Docker.app/Contents/MacOS/com.docker.diagnose check I see
[2023-11-28T20:37:19.832714000Z][com.docker.diagnose.ipc][W] (c4f9edb7) 05552d74-diagnose C<-S NoResponse GET /idle (1.214209ms): Get "http://ipc/idle": dial unix <HOME>/Library/Containers/com.docker.docker/Data/backend.sock: connect: no such file or directory
[2023-11-28T20:37:27.894723000Z][com.docker.diagnose.ipc][I] (b192c3da) 05552d74-diagnose C->S BackendAPI GET /idle
[2023-11-28T20:37:27.894996000Z][com.docker.diagnose.ipc][W] (b192c3da) 05552d74-diagnose C<-S NoResponse GET /idle (270.458µs): Get "http://ipc/idle": dial unix <HOME>/Library/Containers/com.docker.docker/Data/backend.sock: connect: no such file or directory
  1. Tried adding sudo ln -s ~/.docker/run/docker.sock /var/run/docker.sock but it seems like the sock is just never created
@SachaTe SachaTe added the bug Something isn't working label Nov 28, 2023
@bryanmacfarlane
Copy link
Member

does this help? https://stackoverflow.com/questions/44084846/cannot-connect-to-the-docker-daemon-on-macos

@James-Mart
Copy link

I also need docker on the latest m1 runners. I'm trying to build arm64 images natively without qemu emulation (because emulation is too slow).

@SachaTe
Copy link
Author

SachaTe commented Dec 5, 2023

@James-Mart you figure anything out ? All my attempts have failed

@James-Mart
Copy link

James-Mart commented Dec 6, 2023

@James-Mart you figure anything out ? All my attempts have failed

Same, all my attempts failed. I've decided to simply wait until arm64 linux runners are available, which presumably will have docker. That is apparently scheduled for January 2024, or at least will be in private beta.

@khvn26
Copy link

khvn26 commented Dec 6, 2023

Trying to solve the same problems, we've had some success with rogisolorzano/github-runner-ec2-start and rogisolorzano/github-runner-ec2-stop GH actions to spin up our own Graviton EC2 runners.

We tried to spin up OrbStack on GH's M1 runners but they have virtualization disabled so it didn't work.

On EC2, Qemu was still extremely slow in some cases during multiarch builds so we switched to depot.dev for our Docker builds.

@kamesh-09
Copy link

Any update or progress on this ?

@kgantchev
Copy link

macOS runners, such as the ones provided by GitHub, are being run in an ephemeral VM that runs in Apple's virtualization framework. Apple does not support nested virtualization so you can't run Docker inside a macOS VM.

Best Regards,
Kiril Gantchev
CEO and co-founder of FlyCI

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants