Skip to content
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

Makefile should not auto-compute Pulumi CLI version from go.mod file #1310

Open
rquitales opened this issue Jan 21, 2025 · 1 comment
Open
Labels
kind/bug Some behavior is incorrect or out of spec

Comments

@rquitales
Copy link
Member

While on-boarding awsx and aws-apigateway, it was observed that the installed Pulumi CLI version is auto-computed from the provider's go.mod file. This is fine for Go based providers, but we now manage NodeJS based providers like awsx and aws-apigateway. We need better handling of Pulumi CLI versions as the one defined in the go.mod file may not be the same as the version of Pulumi used in the Node provider.

Link to relevant section of the Makefile template:

# Because some codegen depends on the version of the CLI used, we install a local CLI
# version pinned to the same version as `provider/go.mod`.
#
# This logic compares the version of .pulumi/bin/pulumi already installed. If it matches
# the desired version, we just print. Otherwise we (re)install pulumi at the desired
# version.
.pulumi/bin/pulumi: .pulumi/version
@if [ -x .pulumi/bin/pulumi ] && [ "v$$(cat .pulumi/version)" = "$$(.pulumi/bin/pulumi version)" ]; then \
echo "pulumi/bin/pulumi version: v$$(cat .pulumi/version)"; \
touch $@; \
else \
curl -fsSL https://get.pulumi.com | \
HOME=$(WORKING_DIR) sh -s -- --version "$$(cat .pulumi/version)"; \
fi

@pulumi-bot pulumi-bot added the needs-triage Needs attention from the triage team label Jan 21, 2025
@guineveresaenger guineveresaenger added the kind/bug Some behavior is incorrect or out of spec label Jan 22, 2025
@guineveresaenger
Copy link
Contributor

I'm going to classify this as a bug, in the context of node-based providers.

@guineveresaenger guineveresaenger removed the needs-triage Needs attention from the triage team label Jan 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Some behavior is incorrect or out of spec
Projects
None yet
Development

No branches or pull requests

3 participants