将Web API上传到Azure使Blazor Web应用无法访问
我一直在尝试了解我大约一个星期做错了什么。这是我的结构:
我正在发布Blazor Server应用程序编号1。然后,我创建了ASP.NET Web API,在我的本地主机上对其进行了测试,并希望将其上传到Azure以在线访问它。但是,在我在Visual Studio中发布了发布后,我的整个Blazor应用程序不再可以从HTTPS地址访问。然后,我再次从Visual Studio发布了我的Blazor应用程序,它再次工作正常。我做错了什么?是否有任何指南如何发布Blazor Web应用程序,然后在同一Azure帐户上托管ASP.NET Web API?
I have been trying to understand what I am doing wrong for about a week now. Here is my structure:
I am publishing Blazor server app to number 1. Then I have created ASP.Net Web API, tested it on my localhost and would like to upload it to Azure to access it online. However after I am hitting Publish in Visual Studio, my entire Blazor app is not any longer accessible from https address. Then I am Publishing my Blazor app again from Visual Studio and it is working fine again. What I am doing wrong? Is there any guide how to publish Blazor Web App and then host ASP.Net Web API on the same Azure account?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
当然,“在同一Azure帐户上”是可能的,但是当您有2个项目时,您将需要2个应用程序服务,也许是1个服务计划。
两个服务不能共享相同的URL。
我认为您不需要“ API管理服务”,但我可能错了。
"on the same Azure account" is of course possible, but when you have 2 projects you will need 2 App Services, maybe under 1 service plan.
Two services cannot share the same URL.
I don't think you need an "API Management service" but I could be wrong.