简体   繁体   English

我如何git将基于.fsproj的f#项目部署到azure?

[英]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.

相关问题 c#f#:WebApi:如何使用HttpRouteCollection执行与RouteCollection.RouteExistingFiles等效的操作? - c# f#: WebApi: How do I do the equivalent of RouteCollection.RouteExistingFiles with HttpRouteCollection? 在F#中,如何判断对象是否为Async &lt;_&gt;,如何将其转换为Async &lt;_&gt;? - In F#, how do I tell if an object is an Async<_>, and how can I cast it to an Async<_>? F#Web开发-项目 - F# web development - Project 如何使用git在Azure中部署和运行ASP.NET MVC 6 Web API项目 - How to deploy and run an asp.net mvc 6 web api project in azure using git 你如何在F#中使用连字符制作一个控制器? - how do you make a controller in F# that uses hyphens? 我可以在IIS上部署Azure项目吗? - Can i deploy Azure project on IIS? 如何将具有多个组件的应用程序部署到Azure? - How do I deploy an app with multiple components to Azure? 如何在ngrok上部署visual studio项目? - How do I deploy a visual studio project on ngrok? 如何将asp.net core 2.1预览应用程序部署到azure? 我如何在azure中安装新的sdk - How to deploy asp.net core 2.1 preview app to azure?? how do i install the new sdk in azure 基于GIT的asp.net Web应用程序无法部署到带有Typescript编译错误的Azure - GIT based asp.net web app fails to deploy to Azure with typescript compile error
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM