wealdtech / ethdo

Apache License 2.0
284 stars 101 forks source link

Docker container not working on mac #99

Closed fabricus closed 1 year ago

fabricus commented 1 year ago

Hi, I'm try to run the docker container but it keeps on failing. Everything worked well (I mean during setup), I have a pristine docker install (new install on a macos system it was never installed on). When I run the container it stops after something like 1.5s.

It's on macOS 12.6, Docker version 23.0.5, build bc4487a

Any idea? Thanks in advance,

mcdee commented 1 year ago

What happens when you run docker pull wealdtech/ethdo && docker run --rm wealdtech/ethdo version ?

fabricus commented 1 year ago

What happens when you run docker pull wealdtech/ethdo && docker run --rm wealdtech/ethdo version ?

Status: Image is up to date for wealdtech/ethdo:latest
docker.io/wealdtech/ethdo:latest
WARNING: The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested
local build (latest release 1.31.0)
mcdee commented 1 year ago

That looks like it is working, although it it throwing a warning. I have attempted to create a build with the required platform, please could you run that command again and let me know the output? Thanks.

fabricus commented 1 year ago

Thanks a lot, new output:

Using default tag: latest
latest: Pulling from wealdtech/ethdo
Digest: sha256:15c569f9b80ef794385fcf82ad84bdc77ceee4f7a141df4edb48669c98988a28
Status: Image is up to date for wealdtech/ethdo:latest
docker.io/wealdtech/ethdo:latest
local build (latest release 1.31.0)

I've restarted the docker app. When I start the container it stops instantly with the status: exited(0) and therefore it's stopped so I cannot send a command in it.

If I'm trying the same through the terminal I have to do: sudo docker build -t ethdo . And then I end up with: ERROR: failed to solve: failed to read dockerfile: open /var/lib/docker/tmp/buildkit-mount4252841717/Dockerfile: no such file or directory

mcdee commented 1 year ago

ethdo isn't a daemon, it's a command-line tool. So you can use it with (for example):

docker run --rm wealdtech/ethdo chain status

The container will exit once the command completes.

fabricus commented 1 year ago

Thanks a lot, it's now working!