I cannot deploy due to websocket error with metrics service 🤷‍♂️

I’ve been trying to launch a new phoenix app and it is failing due to a websocket error that I cannot seem to get past. The error didn’t appear until the create postgres step of fly launch.

Running fly doctor returns this error:

Pinging WireGuard gateway (give us a sec)... FAILED
(Error: ping gateway: pinger: websocket: failed to WebSocket dial: expected handshake response status code 101 but got 500)

We can't establish connectivity with WireGuard for your personal organization.

WireGuard runs on 51820/udp, which your local network may block.

If this is the first time you've ever used 'flyctl' on this machine, you
can try running 'flyctl doctor' again.

If this was working before, you can ask 'flyctl' to create a new peer for
you by running 'flyctl wireguard reset'.

If your network might be blocking UDP, you can run 'flyctl wireguard websockets enable',
followed by 'flyctl agent restart', and we'll run WireGuard over HTTPS.

I’ve performed these steps and it still fails. Running with LOG_LEVEL=debug reveals a call that raises an error:

DEBUG failed to connect metrics websocket: websocket.Dial wss://flyctl-metrics.fly.dev/socket: bad status

Is this just the service being down? If so, the status page does not reflect this. If this is something else, what can I do about it?

I have been able to deploy before so I tried running flyctl wireguard reset which also returned the error:

Error: websocket: failed to WebSocket dial: expected handshake response status code 101 but got 500

Hi,

There is now an issue on the status page, which may be related.

It may be worth toggling websockets (enable / disable) to see which approach works for you:

Of course if the issue is at Fly’s end, neither will, but it can’t hurt to try.

Hey @rmontgomery429, failing to connect to the metrics server shouldn’t cause any failures so that’s why it’s only visible in debug mode. Are you still having the same issue deploying?