mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-11-28 17:32:44 +08:00
Corrected Azure packaging
--HG-- branch : dev
This commit is contained in:
@@ -15,9 +15,6 @@
|
||||
<WebSitesFolder>$(CompileFolder)\_PublishedWebsites</WebSitesFolder>
|
||||
<StageFolder>$(BuildFolder)\Stage</StageFolder>
|
||||
|
||||
<BuildPlatform Condition="$(ProgramW6432) != ''">x64</BuildPlatform>
|
||||
<BuildPlatform Condition="$(BuildPlatform) == ''">x86</BuildPlatform>
|
||||
|
||||
</PropertyGroup>
|
||||
|
||||
<Import Project="$(LibFolder)\msbuild\MSBuild.Community.Tasks.Targets"/>
|
||||
@@ -51,18 +48,13 @@
|
||||
<MSBuild
|
||||
Projects="$(SrcFolder)\Orchard.Azure\Orchard.Azure.CloudService.sln"
|
||||
Targets="Build"
|
||||
Properties="Configuration=Release;OutputPath=$(CompileFolder)" />
|
||||
Properties="Configuration=Release;OutputPath=$(CompileFolder);PlatformTarget=x64" />
|
||||
|
||||
<MSBuild
|
||||
Projects="$(SrcFolder)\Orchard.Azure.sln"
|
||||
Targets="Build"
|
||||
Properties="Configuration=Release;OutputPath=$(CompileFolder)" />
|
||||
Properties="Configuration=Release;OutputPath=$(CompileFolder);PlatformTarget=x64" />
|
||||
|
||||
<MSBuild
|
||||
Projects="$(SrcFolder)\Orchard.sln"
|
||||
Targets="Build"
|
||||
Properties="Configuration=Release;OutputPath=$(CompileFolder)" />
|
||||
|
||||
</Target>
|
||||
|
||||
|
||||
@@ -96,22 +88,27 @@
|
||||
<Target Name="Package-ForCloud">
|
||||
|
||||
<ItemGroup>
|
||||
<Stage-Bin-Exclude Include="$(WebSitesFolder)\**\bin\**\*" />
|
||||
<Stage-Orchard-Web-Exclude Include="$(WebSitesFolder)\**\Orchard.Web\**\*" />
|
||||
|
||||
<Stage-Themes Include="$(WebSitesFolder)\Orchard.Web\Themes\**\*" />
|
||||
<Stage-Core Include="$(WebSitesFolder)\Orchard.Core\**\*" Exclude="@(Stage-Bin-Exclude)" />
|
||||
<Stage-Modules Include="$(WebSitesFolder)\**\*" Exclude="@(Stage-Core);@(Stage-Bin-Exclude);@(Stage-Orchard-Web-Exclude)" />
|
||||
<Stage-Modules-Bin Include="$(WebSitesFolder)\Orchard.Web\**\bin\*"/>
|
||||
<Excluded Include="$(SrcFolder)\**\bin\**\*;$(SrcFolder)\**\obj\**\*;$(SrcFolder)\**\*.cs;$(SrcFolder)\**\*.csproj*;" />
|
||||
|
||||
<Stage-Themes Include="$(SrcFolder)\Orchard.Web\Themes\**\*" Exclude="@(Excluded)" />
|
||||
<Stage-Core Include="$(SrcFolder)\Orchard.Web\Core\**\*" Exclude="@(Excluded)" />
|
||||
<Stage-Modules Include="$(SrcFolder)\Orchard.Web\Modules\**\*" Exclude="@(Excluded)" />
|
||||
</ItemGroup>
|
||||
|
||||
<Copy SourceFiles="@(Stage-Themes)" DestinationFolder="$(CloudRootFolder)\Themes\%(RecursiveDir)" />
|
||||
<Copy SourceFiles="@(Stage-Core)" DestinationFolder="$(CloudRootFolder)\Core\%(RecursiveDir)" />
|
||||
<Copy SourceFiles="@(Stage-Modules)" DestinationFolder="$(CloudRootFolder)\Modules\%(RecursiveDir)" />
|
||||
<Copy SourceFiles="@(Stage-Modules-Bin)" DestinationFolder="$(CloudRootFolder)\bin\" />
|
||||
|
||||
<Delete Files="$(CloudRootFolder)\App_Data" />
|
||||
|
||||
<ItemGroup>
|
||||
<WebConfigs Include="$(CloudRootFolder)\Modules\*\web.config" />
|
||||
</ItemGroup>
|
||||
|
||||
<Delete Files="@(WebConfigs)" />
|
||||
|
||||
<!-- extra processing of the staged config files -->
|
||||
<XmlUpdate XmlFileName="$(CloudRootFolder)\web.config"
|
||||
<!--<XmlUpdate XmlFileName="$(CloudRootFolder)\web.config"
|
||||
XPath="/configuration/system.web/compilation/@debug"
|
||||
Value="false" />
|
||||
|
||||
@@ -122,26 +119,24 @@
|
||||
<XmlUpdate XmlFileName="$(CloudRootFolder)\Config\Diagnostics.config"
|
||||
XPath="/system.diagnostics/sources/source/@switchValue"
|
||||
Value="Error" />
|
||||
|
||||
<!-- move over extra non-content files the csproj referenced -->
|
||||
<Copy SourceFiles="@(StageProjectAlteration-ExtraFiles->'$(SrcFolder)\Orchard.Web\%(Identity)')"
|
||||
DestinationFolder="$(StageFolder)\%(RecursiveDir)"/>
|
||||
|
||||
<!-- use x64 sqlite for tests depending on build platform -->
|
||||
<Copy
|
||||
SourceFiles="$(LibFolder)\sqlite\x64\System.Data.SQLite.dll"
|
||||
DestinationFiles="$(CloudRootFolder)\bin\System.Data.SQLite.dll" />
|
||||
|
||||
-->
|
||||
|
||||
<Copy
|
||||
SourceFiles="$(SrcFolder)\Orchard.Azure\Orchard.Azure.CloudService\ServiceConfiguration.cscfg"
|
||||
DestinationFolder="$(StageFolder)"
|
||||
/>
|
||||
|
||||
<Copy
|
||||
SourceFiles="$(SrcFolder)\Orchard.Azure\Orchard.Azure.CloudService\Properties.txt"
|
||||
DestinationFolder="$(ServiceFolder)"
|
||||
/>
|
||||
|
||||
</Target>
|
||||
|
||||
<Target Name="Package-Stage">
|
||||
|
||||
<Exec
|
||||
Command=""$(ServiceHostingSDKBinDir)cspack" "$(ServiceFolder)\ServiceDefinition.csdef" /role:Orchard.Azure.Web;"$(CloudRootFolder)";Orchard.Azure.Web.dll /out:"$(StageFolder)\Orchard.cspkg""
|
||||
Command=""$(ServiceHostingSDKBinDir)cspack" "$(ServiceFolder)\ServiceDefinition.csdef" /role:Orchard.Azure.Web;"$(CloudRootFolder)";Orchard.Azure.Web.dll /rolePropertiesFile:Orchard.Azure.Web;"$(ServiceFolder)\Properties.txt" /out:"$(StageFolder)\Orchard.Azure.Web.cspkg""
|
||||
WorkingDirectory="$(CloudRootFolder)"
|
||||
/>
|
||||
|
||||
@@ -149,7 +144,7 @@
|
||||
|
||||
<Target Name="Package-Zip">
|
||||
<ItemGroup>
|
||||
<Zip-Stage Include="$(StageFolder)\ServiceConfiguration.cscfg;$(StageFolder)\Orchard.cspkg" />
|
||||
<Zip-Stage Include="$(StageFolder)\ServiceConfiguration.cscfg;$(StageFolder)\Orchard.Azure.Web.cspkg" />
|
||||
</ItemGroup>
|
||||
|
||||
<MakeDir Directories="$(ArtifactsFolder)" />
|
||||
|
||||
Reference in New Issue
Block a user