Closed mircowidmer closed 6 months ago
This warning is expected for now, it doesn't prevent things from working and will be fixed one day in https://github.com/macOScontainers/macos-jail/issues/11. Could you please show full output of docker run
command?
This warning is expected for now, it doesn't prevent things from working and will be fixed one day in macOScontainers/macos-jail#11. Could you please show full output of
docker run
command?
Thank you. I just retried all the steps listed on the main page. And now the command echo <TOKEN> | docker login ghcr.io -u <GITHUB USERNAME> --password-stdin
never terminates. I realized that I didn't disable the System Integrity Protection, maybe that's the reason why it doesn't end the echo command?
You're supposed to pass your GitHub access token and username in that command. See GitHub Container registry docs on authentication: https://docs.github.com/en/packages/working-with-a-github-packages-registry/working-with-the-container-registry#authenticating-to-the-container-registry
You're supposed to pass your GitHub access token and username in that command. See GitHub Container registry docs on authentication: https://docs.github.com/en/packages/working-with-a-github-packages-registry/working-with-the-container-registry#authenticating-to-the-container-registry
Thanks again for your help. I used my real access tokens from GitHub. I even created a new one before trying it out a second time. Furthermore, I just didn't post them here because I don't like them being publicly accessible.
Well, you alternatively can run docker login ghcr.io
and just type login + token into it.
Furthermore, I just didn't post them here because I don't like them being publicly accessible
Sure, I just trying random guesses about what could go wrong)
docker login ghcr.io
Authenticating with existing credentials...
Login Succeeded
When I run
docker run --rm -it ghcr.io/macoscontainers/macos-jail/ventura:latest echo "Hello from macOS container ^_^"
I still get the following error and warning:
WARNING: The requested image's platform (unknown) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
exec /bin/echo: exec format error
linux/arm64/v8
Do you have Docker Desktop or something like that running? I should have noticed that in your first message) You're trying to run the image with wrong Docker service.
So, I have the same error and I have Docker Desktop running. How can I elegantly switch between docker "services"?
..
Anyways, did it now, maybe not elegantly, but:
failed to resize tty, using default size
Apparently some docker bug, cool. Is it normal that brew says containerd at 0.0.1 and dockerd at 0.0.2?
..
New terminal and now it gives the usual platform warning (the error about tty has gone!) but not the echo output? Error code 255. But I just saw SIP is enabled, I'll try disable it (although I don't like that too much but...)
0.0.2 is ok, there was an update to fix bind mounts: https://github.com/macOScontainers/rund/issues/14#issuecomment-1734421037
Do you have Docker Desktop or something like that running? I should have noticed that in your first message) You're trying to run the image with wrong Docker service.
Thank you. I tried it again and stopped all docker desktop processes. The only one running was dockerd
.
Then I executed
```docker run --rm -it ghcr.io/macoscontainers/macos-jail/ventura:latest echo "Hello from macOS container ^_^"````
and I got this error:
Cannot connect to the Docker daemon at unix:///Users/mirco/.docker/run/docker.sock. Is the docker daemon running?
After starting docker desktop again I encountered the existing problem:
WARNING: The requested image's platform (unknown) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
exec /bin/echo: exec format error
How can I switch between the docker services?
I was able to get the run working by setting DOCKER_HOST env to the correct docker.sock, which if you installed dockerd via brew as described above, should be found at unix:///var/run/docker.sock
So, export DOCKER_HOST=unix:///var/run/docker.sock
Then try your command again. I still get the platform tag warning, which shouldn't be a big deal. But I don't get any output. I think that could be related to SIP. @slonopotamus can you confirm?
Here's my output:
docker run --rm -it ghcr.io/macoscontainers/macos-jail/ventura:latest echo "Hello from macOS container ^_^"
WARNING: The requested image's platform (unknown) does not match the detected host platform (darwin/arm64/v8) and no specific platform was requested
Platform warning is harmless. I created https://github.com/macOScontainers/macos-jail/issues/11 to fix it eventually (need some time to figure out how to publish multiplatform image). Not sure why you're not getting any output though. Will try to figure out where logs are written when Docker works as a service...
I pushed some updates in https://github.com/macOScontainers/homebrew-formula/commit/e559375f12451bf727ca6e2495d50c78e1c108fd. Could you please try updating, restarting containerd + dockerd, and running again? If things still do not work, you should be able to see logs in /opt/homebrew/var/log/containerd.log
+ /opt/homebrew/var/log/dockerd.log
.
Great idea!
I tried it out and failed with the following error message:
WARNING: The requested image's platform (unknown) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
Before I executed the following commands successfully:
I'm running this on this Mac: