I’m not able to connect to that app with fly ssh console too, it’s just connecting. Fly doctor looks ok, I’m able to connect and play with other apps without any problems.
fly ssh console
Connecting to top1.nearest.of.cookienovo-accent.internal... complete
Error error connecting to SSH server: connect tcp [fdaa:0:7c41:a7b:a992:66dd:5ad1:2]:22: operation timed out
Ecto needs to be told about ipv6 in your config/runtime.exs, which newer generated phoenix projects sets for you. In your config/runtime.exs, replace your repo config with the following:
I’m using Phoenix 1.8.1 and still running into the connection issue ( using managed postgres). I have had an active Fly support issue for past 2 days and have been unable to resolve.
I did add your recommended update to the runtime.exs since my project was generated before this pattern was added to generators, so it used to have the hardcoded socket_options: [:inet6].
after re-deploy / restart I still see the :nxdomain log errors when the app tries to connect
excerpt from my runtime.exs
# Check if IPv6 is enabled for Ecto (conditional pattern from newer Phoenix generators)
ecto_ipv6? = System.get_env("ECTO_IPV6") == "true"
# Auto-detect Managed Postgres (has .flympg.net in URL) for automatic SSL/PgBouncer config
is_managed_postgres = String.contains?(database_url, ".flympg.net")
repo_config = [
url: database_url,
socket_options: if(ecto_ipv6?, do: [:inet6], else: []),
pool_size: pool_size,
timeout: 15_000,
queue_target: queue_target,
queue_interval: queue_interval