-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
47 lines (36 loc) · 2.15 KB
/
build.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<StageDir>$(teamcity_build_checkoutDir)\Stage</StageDir>
</PropertyGroup>
<Target Name="Build">
<Message Text="Hello World" Importance="high" />
<Message Text="teamcity_build_checkoutDir = $(teamcity_build_checkoutDir)" Importance="high" />
<MSBuild Projects="$(teamcity_build_checkoutDir)\DockerDemoApp.sln" Properties="Configuration=Release" />
<RemoveDir Condition="Exists($(StageDir))" Directories="$(StageDir)" />
<MakeDir Directories="$(StageDir)" />
<ItemGroup>
<StageFiles Include="$(teamcity_build_checkoutDir)\DockerDemoApp\**\*.cshtml" />
<StageFiles Include="$(teamcity_build_checkoutDir)\DockerDemoApp\**\*.css" />
<StageFiles Include="$(teamcity_build_checkoutDir)\DockerDemoApp\**\*.dll" />
<StageFiles Include="$(teamcity_build_checkoutDir)\DockerDemoApp\**\*.js" />
<StageFiles Include="$(teamcity_build_checkoutDir)\DockerDemoApp\**\*.config" />
<StageFiles Include="$(teamcity_build_checkoutDir)\DockerDemoApp\**\*.html" />
<StageFiles Include="$(teamcity_build_checkoutDir)\DockerDemoApp\**\*.map" />
<StageFiles Include="$(teamcity_build_checkoutDir)\DockerDemoApp\**\*.eot" />
<StageFiles Include="$(teamcity_build_checkoutDir)\DockerDemoApp\**\*.svg" />
<StageFiles Include="$(teamcity_build_checkoutDir)\DockerDemoApp\**\*.ttf" />
<StageFiles Include="$(teamcity_build_checkoutDir)\DockerDemoApp\**\*.woff" />
<StageFiles Include="$(teamcity_build_checkoutDir)\DockerDemoApp\**\*.asax" />
<StageFiles Include="$(teamcity_build_checkoutDir)\DockerFile" />
</ItemGroup>
<Copy SourceFiles="@(StageFiles)" DestinationFolder="$(StageDir)\%(RecursiveDir)\" />
</Target>
<Target Name="DockerBuild">
<PropertyGroup>
<dockerExe>C:\Windows\SysWOW64\docker.exe</dockerExe>
</PropertyGroup>
<Exec Command="$(dockerExe) images" />
<Exec Command="$(dockerExe) build -t dockerdemoapp:0.$(build_number) --pull=false $(StageDir)" />
</Target>
</Project>