You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For Go, it looks like #69 changed machine.NewSecrets to machine.NewSecretsType. (This makes the Go examples incorrect, by the way.) However, it doesn't seem to work as expected.
Let's say talosSecrets represents the result of a machine.NewSecretsType call. We'd then need to use this result (or portions of it) in a number of other places:
We'd need to use the MachineSecrets portion in a machine.GetConfigurationOutput call. This works via talosSecrets.ToSecretTypeOutput().MachineSecrets().
We'd also need to use the ClientConfiguration portion in both machine.NewConfigurationApply and machine.NewBootstrap calls. This does not work using talosSecrets.ToSecretTypeOutput.ClientConfiguration() (incorrect type/type mismatch reported by the IDE and running pulumi preview or pulumi up fails with a go build error).
Ultimately, this means that the provider appears to be broken/non-functional for Go (I have not tested/checked in other languages).
Here is the error received when running pulumi preview or pulumi up:
# github.com/pulumiverse/pulumi-talos/sdk/go/talos/machine
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/secrets.go:49:6: SecretsType redeclared in this block
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/pulumiTypes.go:3190:6: other declaration of SecretsType
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/secrets.go:69:75: cannot use &resource (value of type *SecretsType) as pulumi.Resource value in argument to ctx.RegisterResource: *SecretsType does not implement pulumi.Resource (missing method URN)
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/secrets.go:117:6: SecretsTypeArgs redeclared in this block
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/pulumiTypes.go:3209:6: other declaration of SecretsTypeArgs
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/secrets.go:122:24: method SecretsTypeArgs.ElementType already declared at ../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/pulumiTypes.go:3216:24
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/secrets.go:126:6: SecretsTypeInput redeclared in this block
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/pulumiTypes.go:3201:6: other declaration of SecretsTypeInput
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/secrets.go:195:6: SecretsTypeOutput redeclared in this block
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/pulumiTypes.go:3270:6: other declaration of SecretsTypeOutput
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/secrets.go:197:26: method SecretsTypeOutput.ElementType already declared at ../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/pulumiTypes.go:3272:26
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/secrets.go:201:28: method SecretsTypeOutput.ToSecretsTypeOutput already declared at ../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/pulumiTypes.go:3276:28
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/secrets.go:205:28: method SecretsTypeOutput.ToSecretsTypeOutputWithContext already declared at ../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/pulumiTypes.go:3280:28
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/init.go:29:7: cannot use &SecretsType{} (value of type *SecretsType) as pulumi.Resource value in assignment: *SecretsType does not implement pulumi.Resource (missing method URN)
../../Go/pkg/mod/github.com/pulumiverse/pulumi-talos/[email protected]/go/talos/machine/secrets.go:69:75: too many errors
error: error in compiling Go: unable to run `go build`: exit status 1
The text was updated successfully, but these errors were encountered:
I will have to change the mapping from TF data structures into Pulumi types as there are way to many items either named "machine" or "secrets" in the upstream Talos provider.
For Go, it looks like #69 changed
machine.NewSecrets
tomachine.NewSecretsType
. (This makes the Go examples incorrect, by the way.) However, it doesn't seem to work as expected.Let's say
talosSecrets
represents the result of amachine.NewSecretsType
call. We'd then need to use this result (or portions of it) in a number of other places:machine.GetConfigurationOutput
call. This works viatalosSecrets.ToSecretTypeOutput().MachineSecrets()
.machine.NewConfigurationApply
andmachine.NewBootstrap
calls. This does not work usingtalosSecrets.ToSecretTypeOutput.ClientConfiguration()
(incorrect type/type mismatch reported by the IDE and runningpulumi preview
orpulumi up
fails with ago build
error).Ultimately, this means that the provider appears to be broken/non-functional for Go (I have not tested/checked in other languages).
Here is the error received when running
pulumi preview
orpulumi up
:The text was updated successfully, but these errors were encountered: