使用 TeamCity 设置 Orchard 项目的部署
我们使用 teamcity 来部署我们的几个项目。我正在尝试设置果园项目的部署,目前遇到了一些问题。
我有 teamcity 项目构建并通知成功和失败的构建。当我添加部署步骤并运行它时,出现以下错误:
C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\Web\Microsoft.Web.Publishing.targets(3460, 5):错误 MSB4044:未给“ConcatFullServiceUrlWithSiteName”任务赋值对于所需参数“SiteAppName”。
我不知道是否只是我没有正确配置构建步骤,或者果园是否有问题。有人成功从 TeamCity 部署 Orchard 项目吗?您能帮助阐明这个问题吗?
We use teamcity to deploy several of our projects. I'm attempting to setup the deploy of an orchard project, and I'm currently running into some issues.
I have the teamcity project building and notifying of successful and failed builds. When I add a deploy step and run it, I get the following error:
C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v10.0\Web\Microsoft.Web.Publishing.targets(3460, 5): error MSB4044: The "ConcatFullServiceUrlWithSiteName" task was not given a value for the required parameter "SiteAppName".
I can't tell if it's just me not configuring the build step properly, or if it has trouble with orchard. Has anyone has success deploying orchard projects from TeamCity, and can you help shed some light on this issue?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(6)
我遇到了同样的问题,并通过转到 Visual Studio 项目设置中的“发布/打包 Web”选项卡并在“IIS 网站/应用程序名称”下指定 IIS 网站名称来修复该问题在目标服务器上使用。。
您还可以将 DeployIisAppPath 指定为 TeamCity 中的 MS 构建参数。
I had the same problem and fixed it by going to the 'Publish/Package Web' tab in the Visual Studio project settings and specifying the IIS Website name under 'IIS Web site/application name to use on destination server'.
You can also specify DeployIisAppPath as an MS build arguement in TeamCity.
在项目文件设置中设置以下参数对我有用。
默认网站/MySampleWebSite
Setting the following parameter in the project file settings worked for me.
Default Web Site/MySampleWebSite
我将其添加到 csproj 文件(使用文本编辑器手动编辑)
并解决了错误...
I added this to the csproj file (manual edit using a text editor)
and that took care of the error...
我没有运气使用 Visual Studio 2010 一键发布来部署 Orchard CMS。 *.targets 文件确实存在一些问题。
我认为它应该发布的方式是使用
Orchard.proj
文件。它拥有生成正确的 Web 部署包所需的一切:当您调用 msbuild /t:Build Orchard.proj 时,它会编译所有内容,将适当的文件放置在临时文件夹中的适当位置,然后生成 ~\artifacts\MsDeploy\Orchard.Web.zip< /代码>。
该包已准备好部署。您可能需要根据您想要完成的任务来编辑
manifest.xml
和parameters.xml
。对于Orchard.proj
来说也是如此:您可能希望在那里启用一些禁用的模块等。我还将发布示例 msdeploy 脚本:
deploy.cmd:
可能 这篇博文可能会有所帮助。
I had no luck deploying Orchard CMS using Visual Studio 2010 1-click Publish. It indeed had some problems with *.targets file.
I think the way it should be published is using
Orchard.proj
file. It have everything needed to generate proper web deployment package:When you call
msbuild /t:Build Orchard.proj
, it compiles everything, places proper files at proper locations in temp folders and then generates~\artifacts\MsDeploy\Orchard.Web.zip
.This package is ready to be deployed. You might want to edit
manifest.xml
andparameters.xml
depending on what you want to get done. Same forOrchard.proj
: you might want to enable some of disabled modules there etc.I'm also going to post sample msdeploy script while i'm at it:
deploy.cmd:
Probably this blog post can be helpful.
使用竹子使我的部署自动化时遇到了同样的错误。就我而言,我有两个项目:一个 Web 应用程序项目和一个 Web 应用程序所依赖的类库。当我使用 msbuild 部署命令行 类库依赖项将构建并因缺少 SiteAppName 错误而失败(查看诊断日志,它似乎正在尝试部署我的类库)。
为了解决这个问题,我首先结束了构建整个项目,然后通过将
/p:BuildProjectReferences=false
添加到 msbuild 部署命令行来运行 msbuild 部署,而不重建类库。Ran into the same error getting my deployments automated using bamboo. In my case I have two projects a web application project and a class library that the web application depends on. When I ran the deployment using the msbuild deployment commandline the class library dependency would build and fail with the missing SiteAppName Error (Looking at the diagnostic logs it appears to be trying to deploy my class library).
To get around the problem I ended building the entire project first and then running the msbuild deployment without rebuilding the class library by adding
/p:BuildProjectReferences=false
to the msbuild deployment commandline.我发现了问题,我们没有为 Web 服务器上的部署用户正确设置一些权限。我能够给用户正确的
I found the problem, we had some permissions not correctly set for the deploy user on the web server. I was able to give the user correct