-
Notifications
You must be signed in to change notification settings - Fork 71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Limit download size of the Pulumi CLI? #787
Comments
Hi @slavafomin. I'm inclined to say this request isn't high enough impact to justify the heavy-lifting required to make it work. Would you be able to share an estimate of how long this download is taking on average? It's always helpful to get data from the field :-)
Maybe they're write something like: - uses: pulumi/actions@v3
with:
command: preview
stack-name: org-name/stack-name
runtime: golang That would also not pose much of an issue. In short, I think it would be much more impactful to implement What do you think? Would love to hear your thoughts! :) |
I suppose we didn't have an issue for the optimization I described, so I created one. |
I've got to eat my words. I think you're right, the performance improvement is worthwhile, and there's no reason not to implement it. #837 implements an optimization that skips downloads if a compatible CLI version is present. Right now, when Pulumi is installed, the default language hosts must also be installed. The Pulumi CLI has a subcommand for installing language plugins individually (which was designed to support e.g. YAML) but this subcommand is broken for the language plugins that are considered default (Node, Dotnet, Python, and Go). So unfortunately we couldn't install just Node even if we wanted to. There are a few Nix packages to make this work if you happen to have a runner with Nix installed. I think in combination with #804 we'll squeeze as much performance from these optimizations as possible. If we cache plugins, plus skip redownloading the CLI and language hosts where possible, we should end up without any installation steps on a hosted runner with warm cache. |
N.B. I expect we'll change the core pulumi distribution to fix this at some point. One day a pulumi cli release will just have the cli in it, and dynamically fetch language plugins the same as provider plugins. Probably not worth trying to do all the effort here to work around that for now. |
Yes, I totally agree, that's the path forward in the long run. But it'll take a bit to get there unfortunately. |
Hello!
Issue details
Hello! It looks like this GHA is downloading a 100+ MB archive that includes binaries for all possible languages/platforms, which is a poor idea from the performance standpoint. It would be better to download only required binaries. This will help to reduce network traffic significantly, especially considering that this download happens on every GHA invocation.
Thanks.
Affected area/feature
CLI download.
The text was updated successfully, but these errors were encountered: