customize and make tfgen
This commit is contained in:
@@ -20,10 +20,10 @@ import (
|
||||
// Allow embedding bridge-metadata.json in the provider.
|
||||
_ "embed"
|
||||
|
||||
incus "github.com/lxc/terraform-provider-incus/provider" // Import the upstream provider
|
||||
incus "github.com/lxc/terraform-provider-incus/shim" // Import the upstream provider
|
||||
pfbridge "github.com/pulumi/pulumi-terraform-bridge/v3/pkg/pf/tfbridge"
|
||||
"github.com/pulumi/pulumi-terraform-bridge/v3/pkg/tfbridge"
|
||||
"github.com/pulumi/pulumi-terraform-bridge/v3/pkg/tfbridge/tokens"
|
||||
shimv2 "github.com/pulumi/pulumi-terraform-bridge/v3/pkg/tfshim/sdk-v2"
|
||||
"github.com/pulumi/pulumi/pkg/v3/codegen/schema"
|
||||
|
||||
"github.com/brandonkal/pulumi-incus/provider/pkg/version"
|
||||
@@ -38,7 +38,9 @@ const (
|
||||
mainMod = "index" // the incus module
|
||||
)
|
||||
|
||||
//go:embed cmd/pulumi-resource-incus/bridge-metadata.json
|
||||
// Temporarily comment out the bridge-metadata.json embedding
|
||||
// //go:embed cmd/pulumi-resource-incus/bridge-metadata.json
|
||||
// var metadata []byte
|
||||
var metadata []byte
|
||||
|
||||
// Provider returns additional overlaid schema and metadata associated with the provider.
|
||||
@@ -105,7 +107,7 @@ func Provider() tfbridge.ProviderInfo {
|
||||
// - "github.com/hashicorp/terraform-plugin-framework/provider".Provider (for plugin-framework)
|
||||
//
|
||||
//nolint:lll
|
||||
P: shimv2.NewProvider(incus.New(version.Version)()),
|
||||
P: pfbridge.ShimProvider(incus.Provider()()),
|
||||
|
||||
Name: "incus",
|
||||
Version: version.Version,
|
||||
@@ -135,7 +137,8 @@ func Provider() tfbridge.ProviderInfo {
|
||||
Repository: "https://github.com/brandonkal/pulumi-incus",
|
||||
// The GitHub Org for the provider - defaults to `terraform-providers`. Note that this should
|
||||
// match the TF provider module's require directive, not any replace directives.
|
||||
GitHubOrg: "",
|
||||
GitHubOrg: "lxc",
|
||||
// Temporarily comment out the MetadataInfo
|
||||
MetadataInfo: tfbridge.NewProviderMetadata(metadata),
|
||||
Config: map[string]*tfbridge.SchemaInfo{
|
||||
// Add any required configuration here, or remove the example below if
|
||||
|
||||
Reference in New Issue
Block a user