Reputation: 33
I used the publish feature of Visual Studio to publish my project in a folder. After that I added a Website to IIS on my web server and bound it to the folder where I put all the generated files.
The publish folder looks like this:
The IIS structure looks like this:
When I start the website, it just loads and loads without achieving any result.
Upvotes: 3
Views: 5761
Reputation: 12749
you could follow the below steps to deploy the angular asp.net core app to the iis:
https://dotnet.microsoft.com/en-us/download/dotnet/6.0
Open the project in a visual studio.
Right-click on the project and choose publish:
Set the folder path where you want to publish the site.-> click Finish
Now open iis click on the server name and select add website
While adding a website give any name, select your publish folder and set the port number -> click ok
Upvotes: 2
Reputation: 27997
As Lex said, you should check the browser's develop tool to see what the server replied.
And also I suggest you could try to open the browser to type in the https://youriissitedomain:port/api/controllername
to call your web api to see what server has returned to make sure your asp.net core server-side has works or not.
If it doesn't work, I suggest you could firstly check you have install the right .net core runtime for your server from this article.
Then I suggest you could make sure your IIS web site's application pool has the right permission to access the folder. For more details about how to check ,you could refer to this answer.
Upvotes: 0