Which DUO product are you using and where did you install that?
In my case, I used the DUO for Microsoft Windows Remote Desktop Gateway and installed it on my Remote Desktop Gateway server. I also have an internal DNS and external DNS server, e.g., within my internal network, myip.com = 192.168.131.2; for external nextwork, myip.com = 216.115.132.2. Thus, when my rdp hits myip.com internally, it redirects straight to the RDSH, bypassing RDG.
Just make sure that, in the Remote Desktop Connection (on the client side, that is), in the Advanced tab, the “Connect from anywhere” has either the “Automatic detect RD Gateway server settings” or “Use these RD Gateway server settings” with the “Bypass RD Gateway Server for local addresses” are enabled.
That’s how mine is set up and been running like that for 2 years. Good luck!