Because Utils.ip_version() expects a numeric IP, it can only distinguish numeric IPv4 and IPv6. Therefore, socket_options are again not set according to the IP version for host names:
|
case Utils.ip_version(System.get_env("DB_HOSTNAME", "")) do |
|
case Utils.ip_version(host) do |
The function detect_ip_version defined there, however does DNS lookups and works correctly. Why not use that (again)?
Another option would be to add DNS lookups to Utils.ip_version().
Because
Utils.ip_version()expects a numeric IP, it can only distinguish numeric IPv4 and IPv6. Therefore,socket_optionsare again not set according to the IP version for host names:logflare/config/runtime.exs
Line 150 in ef19231
logflare/config/runtime.exs
Line 284 in ef19231
The function
detect_ip_versiondefined there, however does DNS lookups and works correctly. Why not use that (again)?Another option would be to add DNS lookups to
Utils.ip_version().