diff options
author | MichaelSimons <msimons@microsoft.com> | 2017-03-22 22:43:49 +0300 |
---|---|---|
committer | MichaelSimons <msimons@microsoft.com> | 2017-03-22 22:43:49 +0300 |
commit | 06230984aded800ba3637fbfa6e1f032e604ae1b (patch) | |
tree | bbc1bc3df73262f9afc2ed04c9c1c9ac13080088 /buildpipeline/DotNet-CoreFx-Trusted-Linux.json | |
parent | d38fd4a0a6b0bb55dc5dad3a88cbfe8e29a26153 (diff) |
Add more robust cleanup to linux build defs
Diffstat (limited to 'buildpipeline/DotNet-CoreFx-Trusted-Linux.json')
-rw-r--r-- | buildpipeline/DotNet-CoreFx-Trusted-Linux.json | 63 |
1 files changed, 42 insertions, 21 deletions
diff --git a/buildpipeline/DotNet-CoreFx-Trusted-Linux.json b/buildpipeline/DotNet-CoreFx-Trusted-Linux.json index 35b0d74995..a075914753 100644 --- a/buildpipeline/DotNet-CoreFx-Trusted-Linux.json +++ b/buildpipeline/DotNet-CoreFx-Trusted-Linux.json @@ -252,8 +252,8 @@ }, { "enabled": true, - "continueOnError": false, - "alwaysRun": false, + "continueOnError": true, + "alwaysRun": true, "displayName": "Remove old docker build logs", "timeoutInMinutes": 0, "task": { @@ -286,9 +286,9 @@ }, { "enabled": true, - "continueOnError": false, - "alwaysRun": false, - "displayName": "Stop detached docker container", + "continueOnError": true, + "alwaysRun": true, + "displayName": "Remove container", "timeoutInMinutes": 0, "task": { "id": "d9bafed4-0b18-4f58-968d-86655b4d2ce9", @@ -297,16 +297,35 @@ }, "inputs": { "filename": "docker", - "arguments": "stop $(PB_DockerContainerName)", + "arguments": "rm -f $(PB_DockerContainerName)", "workingFolder": "", "failOnStandardError": "false" } }, { "enabled": true, - "continueOnError": false, - "alwaysRun": false, - "displayName": "Remove container", + "continueOnError": true, + "alwaysRun": true, + "displayName": "Copy Publish Artifact: BuildLogs", + "timeoutInMinutes": 0, + "task": { + "id": "1d341bb0-2106-458c-8422-d00bcea6512a", + "versionSpec": "1.*", + "definitionType": "task" + }, + "inputs": { + "CopyRoot": "$(PB_DockerCopyDest)/corefx", + "Contents": "*.log", + "ArtifactName": "BuildLogs", + "ArtifactType": "Container", + "TargetPath": "\\\\my\\share\\$(Build.DefinitionName)\\$(Build.BuildNumber)" + } + }, + { + "enabled": true, + "continueOnError": true, + "alwaysRun": true, + "displayName": "Cleanup Docker", "timeoutInMinutes": 0, "task": { "id": "d9bafed4-0b18-4f58-968d-86655b4d2ce9", @@ -314,29 +333,28 @@ "definitionType": "task" }, "inputs": { - "filename": "docker", - "arguments": "rm $(PB_DockerContainerName)", + "filename": "$(Build.SourcesDirectory)/corefx/Tools/scripts/docker/cleanup-docker.sh", + "arguments": "", "workingFolder": "", "failOnStandardError": "false" } }, { "enabled": true, - "continueOnError": false, + "continueOnError": true, "alwaysRun": true, - "displayName": "Copy Publish Artifact: BuildLogs", + "displayName": "Cleanup VSTS Agent", "timeoutInMinutes": 0, "task": { - "id": "1d341bb0-2106-458c-8422-d00bcea6512a", + "id": "d9bafed4-0b18-4f58-968d-86655b4d2ce9", "versionSpec": "1.*", "definitionType": "task" }, "inputs": { - "CopyRoot": "$(PB_DockerCopyDest)/corefx", - "Contents": "*.log", - "ArtifactName": "BuildLogs", - "ArtifactType": "Container", - "TargetPath": "\\\\my\\share\\$(Build.DefinitionName)\\$(Build.BuildNumber)" + "filename": "$(Build.SourcesDirectory)/corefx/Tools/msbuild.sh", + "arguments": "/p:AgentDirectory=$(Agent.HomeDirectory) /p:DoClean=$(PB_CleanAgent)", + "workingFolder": "$(Build.SourcesDirectory)/corefx/Tools/scripts/vstsagent/", + "failOnStandardError": "false" } } ], @@ -383,7 +401,7 @@ "value": "/root/corefx" }, "PB_DockerContainerName": { - "value": "$(Build.BuildId)" + "value": "corefx-$(Build.BuildId)" }, "PB_DockerImageName": { "value": "$(PB_DockerRepository):$(PB_DockerTag)" @@ -440,12 +458,15 @@ "allowOverride": true }, "PB_BuildTestsArguments": { - "value": "-BuildArch=x64 -Debug -SkipTests", + "value": "-BuildArch=x64 -Release -SkipTests", "allowOverride": true }, "PB_CreateHelixArguments": { "value": "/t:CloudBuild /p:ArchGroup=x64 /p:ConfigurationGroup=Debug /p:\"EnableCloudTest=true /p:\"TestProduct=corefx /p:\"TimeoutInSeconds=1200\" /p:\"TargetOS=Linux\" /p:FilterToOSGroup=Linux", "allowOverride": true + }, + "PB_CleanAgent": { + "value": "true" } }, "demands": [ |