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
docker build failed: exit status 1: ERROR: use docker --context=default buildx
to switch to context "default"
#4392
Comments
could you paste the output of |
Hmmm... ERROR: open /Users/user/.docker/buildx/activity/desktop-linux: permission denied @caarlos0 what I miss? EDIT: Okay, I fixed this error by following this comment: https://stackoverflow.com/questions/75686903/open-users-user-docker-buildx-current-permission-denied-on-macbook The ouput of NAME/NODE DRIVER/ENDPOINT STATUS BUILDKIT PLATFORMS
colima * docker
colima colima running v0.10.6+d52b2d5 linux/arm64, linux/amd64, linux/amd64/v2
default error
desktop-linux error
Cannot load builder default: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
Cannot load builder desktop-linux: Cannot connect to the Docker daemon at unix:///Users/viktorsostak/.docker/run/docker.sock. Is the docker daemon running? I use |
I just ran into the same/similar error:
This is the config:
But I my
|
I think that if you could add |
Unfortunately that seems to end up in the wrong place. What I get is
It seems it has to come before buildx. |
ah, correct... okay, so we'll need to fix this in another way, will take a proper look later |
Or just run |
@dunglas That would be too easy! (embarrassed sarcasm) Thanks :) If the switch is persistent maybe there isn't much to do in code really. |
maybe we could at least document this better though... if anyone wants to give a swing at PR-ing that :D |
We could search for "to switch to context" in the error message and output some more information right from |
I think we could yeah, maybe search for that, and thrown an error with an URL pointing to a better explanation, like this one for example: https://goreleaser.com/errors/dirty/ |
I would tend to agree here, there is no reason to force the use of the default context. According to the docs, the
With that in mind I tried removing $ docker context ls
NAME DESCRIPTION DOCKER ENDPOINT ERROR
colima * colima unix:///Users/me/.colima/default/docker.sock
default Current DOCKER_HOST based configuration unix:///var/run/docker.sock
$ docker buildx ls
NAME/NODE DRIVER/ENDPOINT STATUS BUILDKIT PLATFORMS
colima * docker
colima colima running v0.11.7+d3e6c1360f6e linux/arm64, linux/amd64, linux/amd64/v2
default error
Cannot load builder default: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running? And it works just fine =) |
refs #4392 Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
I think I agree, playing with it in #4566 |
What happened?
When I run
goreleaser release
, the process reaches the section with Docker image creation and an error appears:docker build failed: failed to build gowebly/gowebly:latest-arm64: exit status 1: ERROR: use `docker --context=default buildx` to switch to context "default"
My
.goreleaser.yml
:How can we reproduce this?
goreleaser release
goreleaser version
GitVersion: 1.21.2 GitCommit: 26fed97a0defe4e73e3094cb903225d5445e5f0d GitTreeState: false BuildDate: 2023-09-26T11:20:15Z BuiltBy: goreleaser GoVersion: go1.21.1 Compiler: gc ModuleSum: h1:dgYtIS7aZlQuRMUMLCjDCOs4lWss85Oh60RDSO0rbWU= Platform: darwin/arm64
GoReleaser Check
Search
Supporter
Code of Conduct
Additional context
The text was updated successfully, but these errors were encountered: