[英]How do I git deploy an .fsproj based f# project to azure?
I have an ASP.NET core application that I've been auto-deploying to an azure app service on commit to a git repo. 我有一个ASP.NET核心应用程序,我已经在提交到git repo时自动部署到azure app服务。 It worked fine as a project.json type project. 它作为project.json类型的项目工作得很好。
I've converted my project.json to myproject.fsproj and it builds and runs locally. 我已将project.json转换为myproject.fsproj,并在本地构建和运行。 On comitting the .fsproj to git, the deployment was triggered, but it failed with the activity log containing one line: 'D:\\home\\site\\repository\\myproject.fsproj' is not a deployable project. 在将.fsproj命名为git时,部署已被触发,但它失败,活动日志包含一行:'D:\\ home \\ site \\ repository \\ myproject.fsproj'不是可部署的项目。
I guess it's an issue with the default kudu deployment script? 我想这是默认的kudu部署脚本的问题? Does anyone know how to sort this out, or do I need to submit an issue/RFC to the kudu guys? 有谁知道如何解决这个问题,还是我需要向kudu人提交问题/ RFC?
UPDATE UPDATE
I generated the original .fsproj using: dotnet new mvc --language f# --framework netcoreapp1.0
我用以下方法生成了原始的.fsproj: dotnet new mvc --language f# --framework netcoreapp1.0
I've since made changes to it, so I will try to do a minimal case later tonight. 我已经对它进行了修改,所以今晚我会尝试做一个小例子。
Turns out that the default deployment in azure wouldn't deal with this. 事实证明,azure中的默认部署不会解决这个问题。
Following the answer on Kudu Deployment Script for ASP.NET Core 1.0 , I generated a custom deployment script using: 根据关于ASP.NET Core 1.0的Kudu部署脚本的答案,我使用以下方法生成了一个自定义部署脚本:
npm install -g kuduscript
kuduscript -y --aspNetCore myproject.fsproj
Added the resulting deploy.cmd along with a .deployment: 添加了生成的deploy.cmd以及.deployment:
[config] command = deploy.cmd
A deployment triggered by a push to git works as expected now. 由推送到git触发的部署现在按预期工作。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.