Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can VS Code be configured to run and debug with IIS Express and ASP.NET core?

I have been able to run ASP.NET core applications with Visual Studio 2017. Visual Studio has the integration of IIS Express and ASP.NET core all setup and it works with F5.

I would like to get this same functionality in VS Code. I have found and tried the IIS extensions for VS code. They serve the files without launching the dotnet.exe process.

How can I configure my VS Code project to provide similar run/debug functionality as Visual Studio 2017?

like image 801
Matthew MacFarland Avatar asked Aug 17 '17 13:08

Matthew MacFarland


People also ask

How do I run VSCode in IIS Express?

The VSCode command pallete is your friend. Press F1 on the keyboard and start typing IISExpress to see the list of commands to use. Alternatively is version 1.2.

How do I debug IIS Express?

To start debugging, select IIS Express (<Browser name>) or Local IIS (<Browser name>) in the toolbar, select Start Debugging from the Debug menu, or press F5. The debugger pauses at the breakpoints. If the debugger can't hit the breakpoints, see Troubleshoot debugging.

How do I debug IIS from Visual Studio?

We can easily debug any web application that is hosted on IIS by attaching worker process of that application to Visual Studio as shown below. From Visual Studio IDE > Tools > Attach to Process Select the particular Process, then start debugging. Now, enjoy debugging with Visual Studio.

How do I configure IIS Express?

Configure IIS express on visual studioSelect the web application project and open properties -> select the web tab -> under server's select IIS express-> Specify the project URL. Now open the project folder and . vs folder (Hidden) -> Config -> applicationhost.


1 Answers

There is an extension available in visual studio market place which can be used to configure and host web applications in IIS Express from VS Code. Check it our here. https://marketplace.visualstudio.com/items?itemName=warren-buckley.iis-express

like image 132
yenkay Avatar answered Sep 16 '22 14:09

yenkay