Dumb question, but I cannot find it. Why does IIS express use 2 ports (Sample file below).
Secondly, in this exercise here, when I'm requested to setup an app, it references 3007, which I cannot access. https://learn.microsoft.com/en-us/learn/modules/identity-application-types/5-exercise-web-apps-call-apis
{
"iisSettings": {
"windowsAuthentication": false,
"anonymousAuthentication": true,
"iisExpress": {
"applicationUrl": "https://localhost:3007",
"sslPort": 3007
}
},
"profiles": {
"IIS Express": {
"commandName": "IISExpress",
"launchBrowser": true,
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
}
},
"IdentityWeb": {
"commandName": "Project",
"dotnetRunMessages": "true",
"launchBrowser": true,
"applicationUrl": "https://localhost:5001;http://localhost:5000",
"environmentVariables": {
"ASPNETCORE_ENVIRONMENT": "Development"
}
}
}
}
iisSettings
is used when running VS2019 or other visual studio version IDE.
IdentityWeb
(peojectname) is for dotnet command line use.
Offical doc: Development and launchSettings.json
These are just different configurations of the project according to the operating environment, no need to entangle.
Delete iisSettings
in vs2019, then change properties, then check launchSettings.json
file.
Before deleted the ssl port is 44316, then we delete it. After changed properties, it generated new ssl port.
Now, we can run project(we need to restart IDE [vs2019]), it works fine.