diff --git a/ElectronNET.Host/main.js b/ElectronNET.Host/main.js index c5f9062..8a87ada 100644 --- a/ElectronNET.Host/main.js +++ b/ElectronNET.Host/main.js @@ -99,10 +99,10 @@ function startSocketApiBridge(port) { server.listen(port, 'localhost'); server.on('listening', function () { console.log('Electron Socket started on port %s at %s', server.address().port, server.address().address); + // Now that socket connection is established, we can guarantee port will not be open for portscanner + startAspCoreBackend(port); }); - startAspCoreBackend(port); - io.on('connection', (socket) => { global['electronsocket'] = socket; global['electronsocket'].setMaxListeners(0); diff --git a/buildReleaseNuGetPackages.sh b/buildReleaseNuGetPackages.sh new file mode 100755 index 0000000..2771bb6 --- /dev/null +++ b/buildReleaseNuGetPackages.sh @@ -0,0 +1,15 @@ +echo "Start building Electron.NET dev stack..." + +echo "Restore & Build API" +cd ElectronNET.API && \ +dotnet restore && \ +dotnet build --configuration Release --force /property:Version=5.22.12 && \ +dotnet pack /p:Version=5.22.12 --configuration Release --force --output "%~dp0artifacts"; + +cd ../; + +echo "Restore & Build CLI" +cd ElectronNET.CLI && \ +dotnet restore && \ +dotnet build --configuration Release --force /property:Version=5.22.12 && \ +dotnet pack /p:Version=5.22.12 --configuration Release --force --output "%~dp0artifacts";