asp.net-mvc – 如何使用MsBuild MsDeployPublish来定位本地文件系统?
发布时间:2020-05-28 06:59:48 所属栏目:asp.Net 来源:互联网
导读:我试图复制Visual Studio 2010“发布…”命令(适用于Web应用程序项目),我将在UI中选择发布方法:“文件系统”. 我的尝试是… %msbuild% /t:MsDeployPublish /property:MsDeployServiceUrl=”file:///d:MyDeploymentFolder”;MsDeployPublishMethod=”File Sys
|
我试图复制Visual Studio 2010“发布…”命令(适用于Web应用程序项目),我将在UI中选择发布方法:“文件系统”. 我的尝试是…
…并尝试了“FileSystem”,“File System”,“Local”等几种方法. 我得到的错误意味着MsDeploy仍然试图推送到IIS服务器: "D:MySourceFolderProject.csproj" (MsDeployPub
lish target) (1) ->
(MSDeployPublish target) ->
C:Program Files (x86)MSBuildMicrosoftVisualStudiov10.0WebMicrosoft.Web
.Publishing.targets(3847,5): error : Web deployment task failed.(The metabase k
ey '/lm/w3svc' could not be found.) [D:MySourceFolderProject.csproj]
C:Program Files (x86)MSBuildMicrosoftVisualStudiov10.0WebMicrosoft.Web.P
ublishing.targets(3847,5): error : r [D:MySourceFolderProject.csproj]
C:Program Files (x86)MSBuildMicrosoftVisualStudiov10.0WebMicrosoft.Web.P
ublishing.targets(3847,5): error : The metabase key '/lm/w3svc' could not be fo
und.r [D:MySourceFolderProject.csproj]
C:Program Files (x86)MSBuildMicrosoftVisualStudiov10.0WebMicrosoft.Web.P
ublishing.targets(3847,5): error : Unable to access the IIS configuration syste
m. Please make sure you have IIS 7 (or later) installed.r [D:MySourceFolderProject.csproj]
C:Program Files (x86)MSBuildMicrosoftVisualStudiov10.0WebMicrosoft.Web.P
ublishing.targets(3847,5): error : Retrieving the COM class factory for compone
nt with CLSID {2B72133B-3F5B-4602-8952-803546CE3344} failed due to the followin
g error: 80040154 Class not registered (Exception from HRESULT: 0x80040154 (REG
DB_E_CLASSNOTREG)). [D:MySourceFolderProject.csproj]
如何定位文件系统进行部署,因为Visual Studio通常允许我在GUI中? 解决方法根据我从 Using MSBuild,how do I build an MVC4 solution from the command line (applying Web.config transformations in the process) and output to a folder?的答案msbuild ProjectFile.csproj /p:Configuration=Release ^
/p:Platform=AnyCPU ^
/t:WebPublish ^
/p:WebPublishMethod=FileSystem ^
/p:DeleteExistingFiles=True ^
/p:publishUrl=c:output
或者如果您正在构建解决方案文件: msbuild Solution.sln /p:Configuration=Release ^
/p:DeployOnBuild=True ^
/p:DeployDefaultTarget=WebPublish ^
/p:WebPublishMethod=FileSystem ^
/p:DeleteExistingFiles=True ^
/p:publishUrl=c:output (编辑:安卓应用网) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
相关内容
- ASP.NET MVC3(Razor)中的视图中局部变量的简单增量
- iis-7 – 主域和可信域之间的信任关系失败
- asp.net-mvc – Ajax.BeginForm,调用操作,返回JSON,如何在我
- asp.net – Chrome在成功的文件下载(200状态)上显示“已取消
- asp.net-web-api – 将JSON数组从Javascript传递到Web API
- ASP.NET MVC URL在CSS文件中自动解析
- asp.net – 无法在UpdatePanel中下载文件
- asp.net-mvc – ELMAH和SQL Server 2008 R2?
- asp.net简单生成XML文件的方法
- asp.net-web-api – 无法使MVC4 WebApi包含JSON中的空字段
推荐文章
站长推荐
- asp.net – web.config文件中的特殊字符
- asp.net-mvc – 如何在单个视图中使用两个表单
- Asp.Net GridView获取TemplateField上的当前行
- 使用ASP.NET MVC 3和实体框架4.1代码首先在SQL C
- asp-classic – 经典的ASP gremlims,每当使用HTM
- asp.net-mvc – Ajax.BeginForm,调用操作,返回JS
- asp.net-mvc – 用于电话号码或社会安全号码的Di
- ASP.NET WebHooks和Signal-R之间的区别
- asp.net-mvc – MVC中TextBoxFor的DisplayFormat
- asp.net-mvc – 模型绑定和GET请求?
热点阅读
