When viewing a Site's page in the Experience Editor, the Editor does not load and the following error message is displayed;
Unable to connect to the remote server
The CM server logs displays the following entry
ERROR [JSS] Error occurred during POST to remote rendering host: `http://localhost:5000`
ERROR Unable to connect to the remote server
Exception: System.Net.WebException
Message: Unable to connect to the remote server
Source: System
at System.Net.WebClient.UploadDataInternal(Uri address, String method, Byte[] data, WebRequest& request)
at System.Net.WebClient.UploadString(Uri address, String method, String data)
at Sitecore.JavaScriptServices.ViewEngine.Http.RenderEngine.Invoke[T](String moduleName, String functionName, Object[] functionArgs)
Nested Exception
Exception: System.Net.Sockets.SocketException
Message: No connection could be made because the target machine actively refused it 127.0.0.1:5000
Source: System
at System.Net.Sockets.Socket.DoConnect(EndPoint endPointSnapshot, SocketAddress socketAddress)
at System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Exception& exception)
However the page loads correctly when browsing the page directly on the Next app