#pruning cache
1 messages ยท Page 1 of 1 (latest)
Hi @undone bay,
The way I'm doing it atm is using this trick:
// cache burst logic, after installation
if noCache {
s := uniuri.New()
ctr = ctr.WithEnvVariable("FOO", s)
}
I basically generate a random string, and append it to my container (as an env var). As it will be different everytime I run it, it will burst the cache at this given layer, and force updating each subsequent layer ๐
By the way, this feature existed, but not on current Dagger CLI, you're right ๐ Could you please make an issue out-of-it ? (if this solution isn't enough for your needs)
That works, I think a dedicated env var or something would be useful. I'll make an issue or pull request if I have the time
I think an issue is a safer bet (or a PR on the docs). But at the engine level, we prefer to discuss these things first with the community ๐