[英]How to install VC++ 2010 Redistributable On Azure App Service
I have hosted my web app on Azure as azure app service.我在 Azure 上托管了我的 Web 应用程序作为 azure 应用程序服务。 There is an error in the application due to a third-party library.
由于第三方库,应用程序出现错误。 Which says it needs to install VC++ 2010 Redistributable (x64) on the server.
这表示它需要在服务器上安装 VC++ 2010 Redistributable (x64)。 how to do that on Azure app service?
如何在 Azure 应用服务上做到这一点?
In short: you don't.简而言之:你没有。 Azure App Service is a PaaS offering, you don't get to decide what gets installed on the machines you run it on.
Azure 应用服务是一种 PaaS 产品,你无法决定在运行它的机器上安装什么。 They run within a sandbox that protects your App Service from doing harm (and being harmed).
它们在沙箱中运行,以保护您的应用服务免受伤害(和受到伤害)。 More info on the sandbox can be found here: Azure Web App sandbox .
可以在此处找到有关沙箱的更多信息: Azure Web App 沙箱。
Apparently some versions of the VC++ Redistributable are already installed on an Azure App Service.显然,某些版本的 VC++ Redistributable 已经安装在 Azure 应用服务上。 Please refer to this article for more info: Visual C++ Redistributable Packages for Visual Studio Azure App Service
更多信息请参考这篇文章: Visual C++ Redistributable Packages for Visual Studio Azure App Service
An alternative solution would be to run a VM where you can manage the OS and the installed libraries yourself.另一种解决方案是运行虚拟机,您可以在其中自行管理操作系统和已安装的库。
I created a simple Nuget package which contains the 3 DLLs and then added that to my app;我创建了一个简单的 Nuget 包,其中包含 3 个 DLL,然后将其添加到我的应用程序中; it then works as the app looks in the local bin folder first.
然后它会在应用程序首先在本地 bin 文件夹中查找时工作。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.