Skip to content

Commit

Permalink
Update common Docker engineering infrastructure with latest
Browse files Browse the repository at this point in the history
  • Loading branch information
dotnet-docker-bot committed Nov 7, 2024
1 parent 0f8eee0 commit db2ef88
Show file tree
Hide file tree
Showing 9 changed files with 48 additions and 19 deletions.
2 changes: 1 addition & 1 deletion eng/common/Install-DotNetSdk.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,6 @@ else {
}

# See https://github.com/NuGet/NuGet.Client/pull/4259
$Env:NUGET_EXPERIMENTAL_CHAIN_BUILD_RETRY_POLICY = "3,1000"
$Env:NUGET_EXPERIMENTAL_CHAIN_BUILD_RETRY_POLICY = "6,1500"

if ($InstallFailed) { throw "Failed to install the .NET Core SDK" }
2 changes: 2 additions & 0 deletions eng/common/templates/jobs/post-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ jobs:
- template: /eng/common/templates/steps/download-build-artifact.yml@self
parameters:
targetPath: $(Build.ArtifactStagingDirectory)
# This can fail if no build jobs ran to produce any artifacts
continueOnError: true
- powershell: |
# Move all image-info artifacts to their own directory
New-Item -ItemType Directory -Path $(imageInfosHostDir)
Expand Down
45 changes: 30 additions & 15 deletions eng/common/templates/jobs/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -107,21 +107,22 @@ jobs:
- script: mkdir -p $(Build.ArtifactStagingDirectory)/eol-annotation-data
displayName: Create EOL Annotation Data Directory
- script: >
$(runImageBuilderCmd) publishImageInfo
'$(imageInfoContainerDir)/image-info.json'
'$(gitHubVersionsRepoInfo.userName)'
'$(gitHubVersionsRepoInfo.email)'
'$(gitHubVersionsRepoInfo.accessToken)'
--git-owner '$(gitHubVersionsRepoInfo.org)'
--git-repo '$(gitHubVersionsRepoInfo.repo)'
--git-branch '$(gitHubVersionsRepoInfo.branch)'
--git-path '$(gitHubImageInfoVersionsPath)'
--image-info-orig-path '$(artifactsPath)/eol-annotation-data/image-info-old.json'
--image-info-update-path '$(artifactsPath)/eol-annotation-data/image-info-new.json'
curl -fSL
--output $(imageInfoHostDir)/full-image-info-orig.json
https://raw.githubusercontent.com/$(gitHubVersionsRepoInfo.org)/$(gitHubVersionsRepoInfo.repo)/refs/heads/$(gitHubVersionsRepoInfo.branch)/$(gitHubImageInfoVersionsPath)
condition: and(succeeded(), eq(variables['publishImageInfo'], 'true'))
displayName: Download Latest Image Info
- script: >
$(runImageBuilderCmd) mergeImageInfo
$(imageInfoContainerDir)
$(imageInfoContainerDir)/full-image-info-new.json
$(manifestVariables)
$(dryRunArg)
$(imageBuilder.commonCmdArgs)
--manifest $(manifest)
--publish
--initial-image-info-path $(imageInfoContainerDir)/full-image-info-orig.json
condition: and(succeeded(), eq(variables['publishImageInfo'], 'true'))
displayName: Publish Image Info
displayName: Merge Image Info
- template: /eng/common/templates/steps/run-imagebuilder.yml@self
parameters:
displayName: Ingest Kusto Image Info
Expand All @@ -148,8 +149,8 @@ jobs:
args: >
generateEolAnnotationData
'$(artifactsPath)/eol-annotation-data/eol-annotation-data.json'
'$(artifactsPath)/eol-annotation-data/image-info-old.json'
'$(artifactsPath)/eol-annotation-data/image-info-new.json'
'$(imageInfoContainerDir)/full-image-info-orig.json'
'$(imageInfoContainerDir)/full-image-info-new.json'
'$(acr.server)'
'$(publishRepoPrefix)'
$(generateEolAnnotationDataExtraOptions)
Expand All @@ -166,6 +167,20 @@ jobs:
parameters:
internalProjectName: ${{ parameters.internalProjectName }}
dataFile: $(artifactsPath)/eol-annotation-data/eol-annotation-data.json
- script: >
$(runImageBuilderCmd) publishImageInfo
'$(imageInfoContainerDir)/full-image-info-new.json'
'$(gitHubVersionsRepoInfo.userName)'
'$(gitHubVersionsRepoInfo.email)'
'$(gitHubVersionsRepoInfo.accessToken)'
--git-owner '$(gitHubVersionsRepoInfo.org)'
--git-repo '$(gitHubVersionsRepoInfo.repo)'
--git-branch '$(gitHubVersionsRepoInfo.branch)'
--git-path '$(gitHubImageInfoVersionsPath)'
$(dryRunArg)
$(imageBuilder.commonCmdArgs)
condition: and(succeeded(), eq(variables['publishImageInfo'], 'true'))
displayName: Publish Image Info
- script: >
$(runImageBuilderCmd) postPublishNotification
'$(publishNotificationRepoName)'
Expand Down
9 changes: 9 additions & 0 deletions eng/common/templates/stages/build-test-publish-repo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ stages:
noCache: ${{ parameters.noCache }}
internalVersionsRepoRef: ${{ parameters.internalVersionsRepoRef }}
publicVersionsRepoRef: ${{ parameters.publicVersionsRepoRef }}
isInternalServicingValidation: ${{ parameters.isInternalServicingValidation }}
- template: /eng/common/templates/jobs/build-images.yml@self
parameters:
name: Linux_amd64
Expand All @@ -104,6 +105,7 @@ stages:
noCache: ${{ parameters.noCache }}
internalVersionsRepoRef: ${{ parameters.internalVersionsRepoRef }}
publicVersionsRepoRef: ${{ parameters.publicVersionsRepoRef }}
isInternalServicingValidation: ${{ parameters.isInternalServicingValidation }}
customInitSteps: ${{ parameters.customBuildInitSteps }}
noCache: ${{ parameters.noCache }}
internalProjectName: ${{ parameters.internalProjectName }}
Expand All @@ -122,6 +124,7 @@ stages:
noCache: ${{ parameters.noCache }}
internalVersionsRepoRef: ${{ parameters.internalVersionsRepoRef }}
publicVersionsRepoRef: ${{ parameters.publicVersionsRepoRef }}
isInternalServicingValidation: ${{ parameters.isInternalServicingValidation }}
customInitSteps: ${{ parameters.customBuildInitSteps }}
noCache: ${{ parameters.noCache }}
internalProjectName: ${{ parameters.internalProjectName }}
Expand All @@ -140,6 +143,7 @@ stages:
noCache: ${{ parameters.noCache }}
internalVersionsRepoRef: ${{ parameters.internalVersionsRepoRef }}
publicVersionsRepoRef: ${{ parameters.publicVersionsRepoRef }}
isInternalServicingValidation: ${{ parameters.isInternalServicingValidation }}
customInitSteps: ${{ parameters.customBuildInitSteps }}
noCache: ${{ parameters.noCache }}
internalProjectName: ${{ parameters.internalProjectName }}
Expand All @@ -158,6 +162,7 @@ stages:
noCache: ${{ parameters.noCache }}
internalVersionsRepoRef: ${{ parameters.internalVersionsRepoRef }}
publicVersionsRepoRef: ${{ parameters.publicVersionsRepoRef }}
isInternalServicingValidation: ${{ parameters.isInternalServicingValidation }}
customInitSteps: ${{ parameters.customBuildInitSteps }}
noCache: ${{ parameters.noCache }}
internalProjectName: ${{ parameters.internalProjectName }}
Expand All @@ -176,6 +181,7 @@ stages:
noCache: ${{ parameters.noCache }}
internalVersionsRepoRef: ${{ parameters.internalVersionsRepoRef }}
publicVersionsRepoRef: ${{ parameters.publicVersionsRepoRef }}
isInternalServicingValidation: ${{ parameters.isInternalServicingValidation }}
customInitSteps: ${{ parameters.customBuildInitSteps }}
noCache: ${{ parameters.noCache }}
internalProjectName: ${{ parameters.internalProjectName }}
Expand All @@ -194,12 +200,14 @@ stages:
noCache: ${{ parameters.noCache }}
internalVersionsRepoRef: ${{ parameters.internalVersionsRepoRef }}
publicVersionsRepoRef: ${{ parameters.publicVersionsRepoRef }}
isInternalServicingValidation: ${{ parameters.isInternalServicingValidation }}
customInitSteps: ${{ parameters.customBuildInitSteps }}
noCache: ${{ parameters.noCache }}
internalProjectName: ${{ parameters.internalProjectName }}
publicProjectName: ${{ parameters.publicProjectName }}
internalVersionsRepoRef: ${{ parameters.internalVersionsRepoRef }}
publicVersionsRepoRef: ${{ parameters.publicVersionsRepoRef }}
isInternalServicingValidation: ${{ parameters.isInternalServicingValidation }}
- template: /eng/common/templates/jobs/build-images.yml@self
parameters:
name: WindowsLtsc2016_amd64
Expand All @@ -213,6 +221,7 @@ stages:
noCache: ${{ parameters.noCache }}
internalVersionsRepoRef: ${{ parameters.internalVersionsRepoRef }}
publicVersionsRepoRef: ${{ parameters.publicVersionsRepoRef }}
isInternalServicingValidation: ${{ parameters.isInternalServicingValidation }}
customInitSteps: ${{ parameters.customBuildInitSteps }}
noCache: ${{ parameters.noCache }}
internalProjectName: ${{ parameters.internalProjectName }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ parameters:
internalVersionsRepoRef: null
publicVersionsRepoRef: null
versionsRepoPath: versions
isInternalServicingValidation: false

steps:
- checkout: self
Expand Down
2 changes: 2 additions & 0 deletions eng/common/templates/steps/download-build-artifact.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ parameters:
targetPath: ""
artifactName: ""
condition: true
continueOnError: false

steps:
- task: DownloadPipelineArtifact@1
Expand All @@ -15,3 +16,4 @@ steps:
artifactName: ${{ parameters.artifactName }}
displayName: Download Build Artifact(s)
condition: and(succeeded(), ${{ parameters.condition }})
continueOnError: ${{ parameters.continueOnError }}
2 changes: 1 addition & 1 deletion eng/common/templates/variables/docker-images.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
variables:
imageNames.imageBuilderName: mcr.microsoft.com/dotnet-buildtools/image-builder:2561667
imageNames.imageBuilderName: mcr.microsoft.com/dotnet-buildtools/image-builder:2575886
imageNames.imageBuilder: $(imageNames.imageBuilderName)
imageNames.imageBuilder.withrepo: imagebuilder-withrepo:$(Build.BuildId)-$(System.JobId)
imageNames.testRunner: mcr.microsoft.com/dotnet-buildtools/prereqs:cbl-mariner2.0-docker-testrunner
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ variables:
- name: testResultsDirectory
value: tests/Microsoft.DotNet.Docker.Tests/TestResults/
- name: officialRepoPrefixes
value: public/,internal/private/
value: public/,internal/private/,unlisted/

- name: mcrDocsRepoInfo.accessToken
value: $(BotAccount-dotnet-docker-bot-PAT)
Expand Down
2 changes: 1 addition & 1 deletion eng/common/templates/variables/dotnet/common.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ variables:
- name: windowsServer2016PublicPoolImage
value: Server2016-NESDockerBuilds
- name: windowsServer2016InternalPoolImage
value: Server2016-NESDockerBuilds-PT
value: Server2016-NESDockerBuilds-1ESPT
- name: windowsServer2016PoolName
value: Docker-2016-${{ variables['System.TeamProject'] }}

Expand Down

0 comments on commit db2ef88

Please sign in to comment.