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

[go/sdk] Remove deprecated providers/Provider resource #1817

Merged
merged 2 commits into from
Dec 3, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
## HEAD (Unreleased)

Breaking change note:

[#1817](https://github.com/pulumi/pulumi-kubernetes/pull/1817) removed the deprecated providers/Provider
resource definition from the Go SDK. Following this change, use the Provider resource at
`github.com/pulumi/pulumi-kubernetes/sdk/v3/go/kubernetes` instead.

- Helm Release: Make RepositoryOpts optional (https://github.com/pulumi/pulumi-kubernetes/pull/1806)
- [go/sdk] Remove deprecated providers/Provider resource (https://github.com/pulumi/pulumi-kubernetes/pull/1817)

## 3.10.1 (November 19, 2021)

Expand Down
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,8 @@ dotnet_sdk::
dotnet build /p:Version=${DOTNET_VERSION}

go_sdk::
# Delete generated SDK before regenerating.
rm -rf sdk/go/kubernetes
$(WORKING_DIR)/bin/$(CODEGEN) -version=${VERSION} go $(SCHEMA_FILE) $(CURDIR)

nodejs_sdk:: VERSION := $(shell pulumictl get version --language javascript)
Expand Down
13 changes: 0 additions & 13 deletions provider/cmd/pulumi-gen-kubernetes/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -372,19 +372,6 @@ func writeGoClient(pkg *schema.Package, outdir string, templateDir string) {
return templateResources.Resources[i].Token < templateResources.Resources[j].Token
})

// We mistakenly included an older version of the Go Provider at
// `github.com/pulumi/pulumi-kubernetes/sdk/v3/go/kubernetes/providers` that was later removed in v3.6.0.
// Re-add this file with deprecation notices in preparation for future removal.
deprecatedComment := "// Deprecated: Use `github.com/pulumi/pulumi-kubernetes/sdk/v3/go/kubernetes` instead"
deprecatedProviderFile := string(files["kubernetes/provider.go"])
deprecatedProviderFile = strings.ReplaceAll(deprecatedProviderFile, "\nfunc", fmt.Sprintf("\n%s\nfunc", deprecatedComment))
deprecatedProviderFile = strings.ReplaceAll(deprecatedProviderFile, "\ntype", fmt.Sprintf("\n%s\ntype", deprecatedComment))
files["kubernetes/providers/provider.go"] = []byte(deprecatedProviderFile)
deprecatedTypesFile := string(files["kubernetes/pulumiTypes.go"])
deprecatedTypesFile = strings.ReplaceAll(deprecatedTypesFile, "\nfunc", fmt.Sprintf("\n%s\nfunc", deprecatedComment))
deprecatedTypesFile = strings.ReplaceAll(deprecatedTypesFile, "\ntype", fmt.Sprintf("\n%s\ntype", deprecatedComment))
files["kubernetes/providers/pulumiTypes.go"] = []byte(deprecatedTypesFile)

files["kubernetes/customPulumiTypes.go"] = mustLoadGoFile(filepath.Join(templateDir, "customPulumiTypes.go"))
files["kubernetes/apiextensions/customResource.go"] = mustLoadGoFile(filepath.Join(templateDir, "apiextensions", "customResource.go"))
files["kubernetes/helm/v2/chart.go"] = mustLoadGoFile(filepath.Join(templateDir, "helm", "v2", "chart.go"))
Expand Down
79 changes: 0 additions & 79 deletions sdk/go/kubernetes/config/pulumiTypes.go

This file was deleted.

251 changes: 0 additions & 251 deletions sdk/go/kubernetes/providers/provider.go

This file was deleted.

Loading