docker / buildx

Docker CLI plugin for extended build capabilities with BuildKit
Apache License 2.0
3.49k stars 471 forks source link

Sail up error with docker - failed to authorize: rpc error: code = Unknown desc = failed to fetch oauth token #873

Open edzis632 opened 2 years ago

edzis632 commented 2 years ago

I have been dealing with this error for hours and can't find a solution on forums. I created new Laravel project and wanted to add sail to it. I used ./vendor/bin/sail up command and this error happened.

Error

Error

Same error: failed to solve with frontend dockerfile.v0: failed to create LLB definition: failed to authorize: rpc error: code = Unknown desc = failed to fetch oauth token: Get "https://auth.docker.io/token?scope=repository%3Alibrary%2Fubuntu%3Apull&service=registry.docker.io": dial tcp 34.192.145.113:443: i/o timeout

What I have tried

Information

Docker version: Version

Windows version: Microsoft Windows [Version 10.0.19042.1348]

WSL versions: Versions

I am new to Laravel and there were a lot of errors I was facing, but this one is the most painful one because I don't know what to look for. Would appreciate any advice on what is this error and how to get past it.

crazy-max commented 2 years ago

dial tcp 34.192.145.113:443: i/o timeout

Looks like a network issue. Is it still happening?

bdharmaraja commented 2 years ago
export DOCKER_BUILDKIT=0
export COMPOSE_DOCKER_CLI_BUILD=0

The ./vendor/bin/sail up is working for me after disabling BuildKit

jamshid commented 1 year ago

Is this because a docker login is required to avoid some rate limiting issue from docker hub? Or is it a fluke? Either way it's not great for giving people confidence. The only workaround is to completely disable buildkit? And at least 10 people have had to do this but the issue is not addressed, at least with a more helpful error message?

razer09 commented 11 months ago

I had the same error and figured out that I was using a VPN. After disabling the VPN, everything worked as expected.