我正在考虑将我们的系统迁移到Windows Azure。目前,我们有一个自动化的过程,使用Team City和NAnt为我们构建所有内容并将其打包到msi中。
有没有办法构建部署所需的包-我不需要它来部署,只需创建包即可。
谢谢
Stu
发布于 2011-10-04 00:03:42
是的,在NANT文件中添加一些命令来打包您的应用程序是非常简单的。
有关示例和参考,请参阅此页面:
http://msdn.microsoft.com/en-us/library/windowsazure/gg432988.aspx
发布于 2011-10-04 00:02:54
有:使用MSBuild
msbuild AzureProject.ccproj /target:publish /p:Configuration=Release;TargetProfile=ReleaseProfile将使用"Release“配置和"ReleaseProfile”Azure配置文件创建一个Azure包。
注意,如果你的Azure项目在一个解决方案文件夹中(比如“文件夹”),你需要例如
msbuild folder\AzureProject.ccproj /target:publish /p:Configuration=Release;TargetProfile=ReleaseProfile发布于 2011-10-04 00:08:58
下面是我的用法:
<echo message="Publishing Azure Package"/>
<exec program="${MSBuildPath}" workingdir="${BuildDirectory}" commandline="Products\SportsCommanderV3\SportsCommanderCloudService\SportsCommanderCloudService.ccproj /t:CorePublish /p:Configuration=Release /p:OutDir=${ReleaseDirectory}\${BuildLabel}\Azure\"/>OurDir部件用于将包发布到我们服务器上的发布目录,但从Azure 1.5SDK开始似乎停止工作,所以现在我添加以下内容:
<copy todir="${ReleaseDirectory}\${BuildLabel}\Azure\Publish">
<fileset basedir="${BuildDirectory}\Products\SportsCommanderV3\SportsCommanderCloudService\bin\Release\app.publish">
<include name="**/*"/>
</fileset>
</copy>https://stackoverflow.com/questions/7637449
复制相似问题