ruidfigueiredo/electron-cgi

Connection keeps getting lost on packaged version of the program

Closed this issue · 1 comments

Hi Rui,

I have been using Electron-CGI in my development of a windows desktop application with a C# backend. Throughout development and when debugging, everything seems to be working correctly. However, when I package the application and run the .exe version of the program, the connection to Electron-CGI is repeatedly lost on startup. Do you have any suggestions on how I can approach this issue?

I have tried different packaging methods, using Electron-Forge and electron-packager.

Any help would be much appreciated, thank you!

Resolved the issue by changing the directory path for the release build in the following line:

connection = new ConnectionBuilder().connectTo('dotnet', 'run', '--project', '[CHANGE PATH HERE]').build();