使用命令运行.netcore web程序时,默认端口为5000,如果需要修改端口,直接在Program入口处新增如下代码即可:

webBuilder.UseUrls("http://*:8080");

修改dotnet运行.netcore web程序默认端口

 

相关文章:

  • 2021-04-24
  • 2021-10-31
  • 2021-10-16
  • 2021-09-01
  • 2022-01-10
  • 2021-11-28
猜你喜欢
  • 2021-12-31
  • 2022-12-23
  • 2021-11-28
  • 2022-12-23
  • 2021-11-28
  • 2021-11-28
  • 2021-05-31
相关资源
相似解决方案