Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
112 changes: 59 additions & 53 deletions eng/pipelines/cleanup-acr-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,57 +10,63 @@ schedules:
always: true

variables:
- template: templates/variables/common.yml
- template: /eng/pipelines/templates/variables/common.yml@self

jobs:
- job: Build
pool:
vmImage: $(defaultLinuxAmd64PoolImage)
steps:
- template: ../common/templates/steps/init-docker-linux.yml
- template: ../common/templates/steps/clean-acr-images.yml
parameters:
internalProjectName: ${{ variables.internalProjectName }}
repo: "build-staging/*"
subscription: $(acr-staging.subscription)
resourceGroup: $(acr-staging.resourceGroup)
acr: $(acr-staging.server)
action: delete
age: 15
- template: ../common/templates/steps/clean-acr-images.yml
parameters:
internalProjectName: ${{ variables.internalProjectName }}
repo: "public/dotnet/*"
subscription: $(acr.subscription)
resourceGroup: $(acr.resourceGroup)
acr: $(acr.server)
action: pruneEol
age: 15
- template: ../common/templates/steps/clean-acr-images.yml
parameters:
internalProjectName: ${{ variables.internalProjectName }}
repo: "test/*"
subscription: $(acr.subscription)
resourceGroup: $(acr.resourceGroup)
acr: $(acr.server)
action: pruneAll
age: 7
- template: ../common/templates/steps/clean-acr-images.yml
parameters:
internalProjectName: ${{ variables.internalProjectName }}
repo: "public/dotnet-buildtools/*"
subscription: $(acr.subscription)
resourceGroup: $(acr.resourceGroup)
acr: $(acr.server)
action: pruneEol
age: 15
customArgs: --exclude $(excludedBuildToolsPrereqsImage)
# Disabled due to https://github.com/dotnet/docker-tools/issues/797
# - template: ../common/templates/steps/clean-acr-images.yml
# parameters:
# repo: "mirror/*"
# subscription: $(acr-staging.subscription)
# resourceGroup: $(acr-staging.resourceGroup)
# arc: $(acr-staging.server)
# action: pruneDangling
# age: 0
extends:
template: /eng/common/templates/1es-official.yml@self
parameters:
serviceConnections:
- name: $(clean.serviceConnectionName)
stages:
- stage: Build
dependsOn: []
jobs:
- job: Build
steps:
- template: /eng/common/templates/steps/init-docker-linux.yml@self
- template: /eng/common/templates/steps/clean-acr-images.yml@self
parameters:
internalProjectName: ${{ variables.internalProjectName }}
repo: "build-staging/*"
subscription: $(acr-staging.subscription)
resourceGroup: $(acr-staging.resourceGroup)
acr: $(acr-staging.server)
action: delete
age: 15
- template: /eng/common/templates/steps/clean-acr-images.yml@self
parameters:
internalProjectName: ${{ variables.internalProjectName }}
repo: "public/dotnet/*"
subscription: $(acr.subscription)
resourceGroup: $(acr.resourceGroup)
acr: $(acr.server)
action: pruneEol
age: 15
- template: /eng/common/templates/steps/clean-acr-images.yml@self
parameters:
internalProjectName: ${{ variables.internalProjectName }}
repo: "test/*"
subscription: $(acr.subscription)
resourceGroup: $(acr.resourceGroup)
acr: $(acr.server)
action: pruneAll
age: 7
- template: /eng/common/templates/steps/clean-acr-images.yml@self
parameters:
internalProjectName: ${{ variables.internalProjectName }}
repo: "public/dotnet-buildtools/*"
subscription: $(acr.subscription)
resourceGroup: $(acr.resourceGroup)
acr: $(acr.server)
action: pruneEol
age: 15
customArgs: $(excludedBuildToolsPrereqsImagesArgs)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, this change is to do with https://dev.azure.com/dnceng/internal/_git/dotnet-installer/pullrequest/50249. I have already updated this pipeline's variables to exclude both images out of an abundance of caution.

# Disabled due to https://github.com/dotnet/docker-tools/issues/797
# - template: ../common/templates/steps/clean-acr-images.yml
# parameters:
# repo: "mirror/*"
# subscription: $(acr-staging.subscription)
# resourceGroup: $(acr-staging.resourceGroup)
# arc: $(acr-staging.server)
# action: pruneDangling
# age: 0