Posted over 4 years ago. Visible to the public. Linked content.
Fixing "SocketError: getaddrinfo: Name or service not known" with Ruby's resolv-replace.rb
we had the same error and google helped us find the linked solution.
require "resolv-replace.rb" during app startup and all should be good.