Error Deploying to Fly

I haven’t been able to deploy to fly for the last 2 months or so. it ends up doing this

 Building 307.1s (0/1)                                                                                                                                                   
 => [internal] load remote build context 

it loads for some 900 secs and dies with an EOF:

[+] Building 956.8s (1/1) FINISHED                                                                                                                                          
 => ERROR [internal] load remote build context                                                                                                                       956.6s
------
 > [internal] load remote build context:
------
Error failed to fetch an image or build from source: error building: error during connect: Post "http://[fdaa:0:65ea:a7b:c988:fb87:8d35:2]:2375/v1.41/build?buildargs=null&buildid=upload-request%3A673106bdf8706e1848337b012b31dbf22308a27043899135c53e03770602afab&cachefrom=null&cgroupparent=&cpuperiod=0&cpuquota=0&cpusetcpus=&cpusetmems=&cpushares=0&dockerfile=&labels=null&memory=0&memswap=0&networkmode=&rm=0&shmsize=0&target=&ulimits=null&version=2": EOF

for context: right now I’m trying to deploy a laravel application, but I had this issue with a node js application too.

if I try fly deploy --local-only, I get:

Error failed to fetch an image or build from source: error building: failed to solve with frontend dockerfile.v0: failed to solve with frontend gateway.v0: rpc error: code = Unknown desc = failed to create LLB definition: circular dependency detected on stage: base

I’d appreciate any help please.

Hi @chibs! One thing you can do is restart your fly agent with the command fly agent restart and retry your deployment.

Another action that might help is to make sure you have the latest flyctl utility running in your environment, you can check your version with fly version. If there’s a latest version you can update to, please do so and see if that helps.

If that still does not work, can you run fly doctor and see if there are any failed output in the debugging process?

*Following the solution here might help as well: https://community.fly.io/t/failed-to-fetch-an-image-or-build-from-source-error-building-unexpected-eof/5938

1 Like