Skip to content

Commit

Permalink
Merge pull request #516 from pulumi/iwahbe/remove-shim-trick
Browse files Browse the repository at this point in the history
Remove shim trick
  • Loading branch information
AaronFriel authored Mar 6, 2023
2 parents 3688381 + 3ec622c commit 8663622
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 1,438 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
From 82d0f20ef70da03c1e36eb675debc6c6f276cd29 Mon Sep 17 00:00:00 2001
From: Ian Wahbe <[email protected]>
Date: Mon, 6 Mar 2023 13:39:15 +0100
Subject: [PATCH] Add `shim.NewProvider` to expose `internal/provider.New`

---
shim/shim.go | 10 ++++++++++
1 file changed, 10 insertions(+)
create mode 100644 shim/shim.go

diff --git a/shim/shim.go b/shim/shim.go
new file mode 100644
index 0000000..fb00354
--- /dev/null
+++ b/shim/shim.go
@@ -0,0 +1,10 @@
+package shim
+
+import (
+ "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema"
+ "github.com/terraform-providers/terraform-provider-docker/internal/provider"
+)
+
+func NewProvider() *schema.Provider {
+ return provider.New("dev")()
+}
--
2.39.1

4 changes: 1 addition & 3 deletions provider/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ require (
github.com/pulumi/pulumi/pkg/v3 v3.56.0
github.com/pulumi/pulumi/sdk/v3 v3.56.0
github.com/stretchr/testify v1.8.2
github.com/terraform-providers/terraform-provider-docker/shim v0.0.0
github.com/terraform-providers/terraform-provider-docker v0.0.0
google.golang.org/grpc v1.53.0
google.golang.org/protobuf v1.28.1
gopkg.in/yaml.v3 v3.0.1
Expand All @@ -25,7 +25,6 @@ replace (
github.com/hashicorp/terraform-plugin-sdk/v2 => github.com/pulumi/terraform-plugin-sdk/v2 v2.0.0-20220725190814-23001ad6ec03
github.com/hashicorp/vault => github.com/hashicorp/vault v1.2.0
github.com/terraform-providers/terraform-provider-docker => ../upstream
github.com/terraform-providers/terraform-provider-docker/shim => ./shim
)

require (
Expand Down Expand Up @@ -236,7 +235,6 @@ require (
github.com/spf13/cast v1.5.0 // indirect
github.com/spf13/cobra v1.6.1 // indirect
github.com/spf13/pflag v1.0.5 // indirect
github.com/terraform-providers/terraform-provider-docker v0.0.0 // indirect
github.com/texttheater/golang-levenshtein v1.0.1 // indirect
github.com/tonistiigi/fsutil v0.0.0-20230214225802-a3696a2f1f27 // indirect
github.com/tonistiigi/units v0.0.0-20180711220420-6950e57a87ea // indirect
Expand Down
96 changes: 0 additions & 96 deletions provider/shim/go.mod

This file was deleted.

Loading

0 comments on commit 8663622

Please sign in to comment.