Closed jhubsharp closed 5 months ago
Could you provide the logs from the output channel when debugging?
You can try specifying the Functions API port to something different than 7071 by using the --api-port
option.
This issue has been closed automatically because it needs more information and has not had recent activity. See also our issue reporting guidelines.
Happy Coding!
Frontend framework: Blazor (dotnet 8)
Do you have a Functions API? Yes, dotnet 8
What is your apps' file structure? Where does your frontend code live? Where does your API live? Blazor app lives in /app, Function lives in /api
Version information for: Functions Core Tools, Static Web Apps CLI, and Node.JS
Did you try using a swa-cli.config.json file? If yes, please provide it.
package.json:
I'm trying to run the CLI from within a WSL instance and debug the application. Using the provided config file I can run the app by using
npm start
with the included package.json so that I don't have to install the SWA CLI globally. For debugging, it looks like I have to install the CLI globally though.When I run the debug command, two processes start: first the app runs the Functions host and binds to port 7071. Then, the SWA CLI runs and also tries to spin up a function on port 7071, whcih fails because the first process has bound the port.
func start
exits with code 1 and the SWA CLI waits forever to connect to the browser.