我如何使用F#天青网站部署Web应用程序 [英] How do I deploy a web application using F# to Azure Web Site
问题描述
当我部署我的web应用程序到Azure的网站,我收到以下错误:
When I deploy my web application to an Azure Web Site, I am getting the following error:
无法加载文件或程序集FSharp.Core,版本= 4.0.0.0,文化=中性公钥= b03f5f7f11d50a3a'或它的一个依赖。该系统找不到指定的文件。
Could not load file or assembly 'FSharp.Core, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.
我在过去部署到IIS服务器时遇到的这一点,并通过安装在F#可再发行的 http://www.microsoft.com/en-us/download/details.aspx?id=13450
I have encountered this in the past when deploying to an IIS server and fixed it by installing the F# redistributable http://www.microsoft.com/en-us/download/details.aspx?id=13450
有谁知道我能做些什么来得到一个蓝色的网站(不是Azure的Web角色)?这方面的工作。
Does anyone know what I can do to get this working on an Azure Web Site (not an Azure Web Role)?
另外,我有复制本地设置为true从它被引用其中FSharp.Core库。
Also, I do have Copy Local set to true for the FSharp.Core library from where it is being referenced.
推荐答案
<子>的评论转贴:
在我的经验中,为了使用F#库在Azure中的C#项目,有必要从C#项目,以 FSharp.Core
直接引用了要上载的适当组件。用C#-to-C#项目引用的复制本地属性似乎-to-F#引用它不与C#正确地传播,而
In my experience, in order to use an F# library from a C# project in Azure, it is necessary to reference FSharp.Core
directly from the C# project in order for the proper assemblies to be uploaded. With C#-to-C# project references the 'Copy Local' property seems to propagate correctly, whereas with C#-to-F# references it does not.
我想与 编译code>标志
可能工作为好,但我没有亲自尝试过。
I assume compiling with the --standalone
flag probably works as well, but I haven't tried it personally.
这篇关于我如何使用F#天青网站部署Web应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!