Change replacedIP to return external hostname instead of IP. This resolves to the internal hostname if queried from inside AWS