Looks like the timeout issues have resolved themselves today.
I went ahead and tried this on a brand new MacStadium bare metal M1, so it’s in a data center.
Waiting for remote builder fly-builder-proud-sound-5393… connecting ⣾ Error error connecting to docker: unable to connect WireGuard tunnel: context deadline exceeded
So it seems like it’s currently not working on Macs at all. Tried fltctl from nixpkgs:
flyctl v0.0.0-1643132251+dev darwin/arm64 Commit: BuildDate: 2022-01-25T12:37:31-05:00
And from homebrew:
fly v0.0.286 darwin/arm64 Commit: cd174ea BuildDate: 2022-01-23T12:22:32Z
So unless I’m doing something wrong, it seems like deploy on Mac (at least silicon) is not working at all. At least for me. Let me know if there’s anything I can do to help diagnose the issue.
I’m also unable to get past the timeout issue. Here’s my flyctl version:
flyctl v0.0.286 darwin/amd64 Commit: cd174ea BuildDate: 2022-01-23T12:22:32Z
I’m on the NJ region, not sure the changes to fix this have propagated to my region yet.
fwiw, here’s my error message:
Waiting for remote builder fly-builder…819… connecting ⣾ Error failed to fetch an image or build from source: error connecting to docker: unable to connect WireGuard tunnel: context deadline exceeded
Same issue here. Waiting for remote builder.
I created a new topic that’s Mac specific with every combination, you can find it here:
Ok! My very first Fly.io “fly launch” command now works. Nice job, thanks. This app has nothing in it, I was just trying out your launch tutorial.
I’m new to Fly, so I was quite ready to deal with the unexpected. Now, “fly open” fails to resolve on my browser, but that looks like a separate issue.
fly open can take a few minutes, when you first create an app we give you an IP address and a DNS entry. The internet is not as fast to get those to your local system as I’d like …
Got it! It makes sense. But overall it’s pretty fast (post launch), it was maybe a minute or 2.
Did you find a solution to this issue? I’m getting the same:
Error failed to fetch an image or build from source: error building: error during connect: Post "http...
I’m trying to deploy from an M1 MacBook Pro with
fly deploy --remote-only.
@Darryl what host was it trying to POST to?
Hi, @michael. Thanks for the reply.
A bit of context: I was just trying to deploy an example Remix app. I’ve never used Remix or Fly.io before so it seemed like a good chance to test both.
I set up the sample app like this:
Then, as shown in the
README.md generated with that project, I tried to deploy with
fly deploy --remote-only once I’d created my account. I’ve tried restarting the agent, deleting the builder, etc. No luck unfortunately.
Update: the sample project has no database; it’s literally a single route with some text.
This is a bad first impression!
The issue you posted earlier looks like a timeout connecting to something. I’m curious if it’s a timeout with our API (api.fly.io), or fetching images from docker hub, or flyctl connecting to the docker daemon in your remote builder. If you know the url from the error it can help narrow it down.
Hi, Michael. Here’s the error, complete with URL. Please tell me if I shouldn’t be sharing this complete URL publicly.
Error failed to fetch an image or build from source: error building: error during connect: Post "http://[fdaa:0:55ae:a7b:23c4:0:b5ba:2]:2375/v1.41/build?buildargs=null&buildid=upload-request%3Ac867feda0ab3dd5bb0476577cc1192eb562d1b7e1d64771ffe62b522bd00d800&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
That URL is safe to share publicly. It looks like it had a problem talking to the remote Docker Daemon.
Your builder is running in Frankfurt, Germany. Is that close to where you are?
Hi, Kurt. Yeah, as close as I can get. I’m in southern Germany so Frankfurt is the closest location.
Dang ok, that’s a weird error then. This could be:
- A very large context. Run
du -shin your app directory, if it’s like 1GB that’s a problem. When you run
fly deployit should tell you the context size. If your context is over >100MB it could make things slow and timeout. You can keep contexts small with a
- Our network agent may be causing a problem.
If this keeps happening and you’re feeling adventurous, you can debug #2 with a a real Wireguard Peer: Private Networking
Then try a deploy using your host wireguard connection:
FLY_REMOTE_BUILDER_HOST_WG=1 fly deploy
du -sh gives me
223M. It’s getting a little late here but I’ll look into your other suggestion over the weekend if I can. Thanks for your help so far!
Oh, and I have a
.dockerignore file containing
Ok well that’s probably not the issue then! That’s a pretty small directory, even with node_modules.