-
Notifications
You must be signed in to change notification settings - Fork 15
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
pluginDownloadURL not implemented #1109
Comments
i can confirm this. the result in my case is: {
"resource": true,
"version": "0.0.1",
"name": ""
} this file should also contain a def genPulumiResources = tasks.register('genPulumiResources') {
doLast {
def resourcesDir = sourceSets.main.output.resourcesDir
def subDir = project.name.replace(".", "/")
def outDir = file("$resourcesDir/$subDir")
outDir.mkdirs()
new File(outDir, "version.txt").text = resolvedVersion
def info = new Object()
info.metaClass.resource = true
info.metaClass.name = ""
info.metaClass.version = resolvedVersion
def infoJson = new groovy.json.JsonBuilder(info).toPrettyString()
new File(outDir, "plugin.json").text = infoJson
}
} as far as i can tell this is due to https://github.com/pulumi/pulumi-java/blob/main/pkg/codegen/java/build.gradle.template#L77-L79 not setting this property at all. the context for this template does not even contain a reference to the hence, it is also not set in https://github.com/pulumi/pulumi-java/blob/main/pkg/codegen/java/templates_gradle.go#L87 which generates the context which is later passed to the template. similar to #1118 this is preventing third-party publishers. |
What happened?
I added a custom URL to the property
pluginDownloadURL
inschema.json
. However this property is not used in the generated java SDK. As a result, when using the generated java SDK the pulumi CLI tries to download the plugin fromhttp://get.pulumi.com/...
and fails:The
build.gradle
file generates aplugin.json
file but this file does not contain aserver
property. Also, the value ofpluginDownloadURL
is not added anywhere else in the generated code.Expected Behavior
The generated SDK should honour the value of
pluginDownloadURL
and download the plugin binary from this URL.Steps to reproduce
Clone https://github.com/hansbarnard/pulumi-test-java and run
make build_java
.Check the content of file
sdk/java/build/resources/main/com/xxxxx/ipidp/plugin.json
Output of
pulumi about
Not applicable.
Additional context
Using java gen v0.9.3
Contributing
Vote on this issue by adding a 👍 reaction.
To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).
The text was updated successfully, but these errors were encountered: