pulumi / get.pulumi.com

The infrastructure behind https://get.pulumi.com.
https://get.pulumi.com
7 stars 7 forks source link

enhance pulumi install scripts to skip downloading + installing if there's not a new version #138

Open joshsleeper opened 1 year ago

joshsleeper commented 1 year ago

Hello!

Issue details

it'd be nice if the install scripts could detect that the currently installed pulumi version is already the latest and short-circuit the download + install process

Affected area/feature

get.pulumi.com install scripts

iwahbe commented 1 year ago

Hi @joshsleeper. Thanks for the suggestion. It would be super helpful if you could explain why this scenario came up. I'm a little concerned about complexity here. We can detect pulumi only if it is on $PATH while we install, and that might not be the version users are using.

joshsleeper commented 1 year ago

so in my head I'd think that check is very likely to succeed, but easy to fallback to current behavior if it fails?

  1. pulumi is already installing to a known, well-documented place
  2. if pulumi isn't on the path for some reason, I'd think that checking that known (and about to be overwritten anyway) path for the current binary is sane
  3. if pulumi can't be found either on the path or by absolute path, I'd just continue as normal

as for the reasoning, it's mostly just the "don't do work you don't need to do" mentality~ less bandwidth usage + I/O for both hosting and users, and a faster update experience for users that are already updated.

iwahbe commented 1 year ago

Thanks for the quick feedback. I'm not sure when we will have bandwidth to address this, but I'm convinced that it would be an improvement.

MaleicAcid commented 1 month ago

+1 really need this