The only way I could get it to work is by adding DNS rewrite rules so internally the sites would resolve to my NGINX reverse proxy.