hi, still there's no way to clean up unused pulumi...
# general
c
hi, still there's no way to clean up unused pulumi plugins? I can't see any related CLI command to figure out which plugins are used by which project/stack, but I'm pretty sure we don't use aws 1.7.0 or cloudflare 1.2.0 etc. plugins anymore. The total plugin cache is almost 7GB, which is unnecessarily big and I want to clean this up, but removing all of the plugins, not a solution, because as far as I know pulumi still does not redownload a plugin if it thinks that already installed and have to do it manually, one by one. Am I correct? What are the alternatives here?
b
pulumi will install the plugins you need using plugin acquisition if you run your package installation mechanisms (ie npm install) on a stack I agree with you though, we should probaby have a mechanism for cleaning up plugins. I've opened an issue for that here: https://github.com/pulumi/pulumi/issues/7505
c
@billowy-army-68599 thanks for the info. My first thought was, that deleting all the plugins and all the relevant pulumi libraries and reinstall them with the package manager would solve the issue. But I checked some of our projects and some of them using multiple versions, e.g:
Copy code
aws 3.33.0
aws 3.4.0
aws 4.10.0
cloudflare 2.14.0
cloudflare 2.6.0
cloudflare 3.2.0
I collected this info from the state file, searching for resources with
pulumi:providers:*
type. So I assume the reinstall idea wouldn't work. When will pulumi update the provider versions for already existing resources? Only when they are updated? Because a simple
pulumi up
does not want to update these. Is it possible to force the resources to use the latest provider versions?