How to delete an Azure Pipeline cache without changing cache key
Asked Answered
M

2

13

I have a task that creates a cache

- task: Cache@2
  inputs:
    key: 'sonarCache'
    path: $(SONAR_CACHE)
    cacheHitVar: CACHE_RESTORED
  displayName: Cache Sonar packages

However, the cache got corrupted. So how do I run this pipeline while telling it to ignore any existing cache ?

For some reason, I cannot change the cache key sonarCache

Mong answered 15/3, 2022 at 18:42 Comment(0)
E
5

There's currently no way to do this. Here is what the documentation says: enter image description here

Extine answered 18/11, 2022 at 9:26 Comment(0)
S
-1

maybe failing the pipeline once will invalidate the existing cache

Spokeshave answered 9/8, 2022 at 18:8 Comment(1)
No it doesn't :/Zebra

© 2022 - 2024 — McMap. All rights reserved.