Skip to content

Commit

Permalink
Merge pull request #9 from rpadovani:change-provider
Browse files Browse the repository at this point in the history
Change provider to alekc/kubectl
  • Loading branch information
rpadovani authored Jul 16, 2024
2 parents fee72c4 + 9a92826 commit f176b90
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 4 deletions.
25 changes: 25 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# terraform-crds-manager

## 1.0.0

- Replace `gavinbunney/kubectl` with `alekc/terraform-provider-kubectl`; this will cause resources to be recreated (and thus the major version bump), but you can avoid that importing them in the new provider following [the linked guide][0];
- Require Terraform 0.13 or newer;

[0]: https://github.com/alekc/terraform-provider-kubectl?tab=readme-ov-file#changing-providers-for-existing-resources

## 0.3.0

With this release, a new variable is available:
- `apply_only`: if true, no CRD will be ever deleted by the module. Default to `false`;

Updating the module doesn't change the current behavior.

## 0.2.0

Thanks to @joelsdc for their first contribution!

With this release, two new variables are available:
`force_new`: Forces delete & create of resources if the `yaml_body` changes;
`force_conflicts`: Allows using `force_conflicts`;

Both of them are optional, and default to false, so updating the module doesn't change the behavior.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ Alongside, let's specify the CRDs we want to manage:
```terraform
module "kube_prometheus_stack_crds" {
source = "rpadovani/helm-crds/kubectl"
version = "0.3.0"
version = "1.0.0"
crds_urls = [
"https://raw.githubusercontent.com/prometheus-community/helm-charts/kube-prometheus-stack-${var.chart_version}/charts/kube-prometheus-stack/crds/crd-alertmanagerconfigs.yaml",
Expand Down Expand Up @@ -64,8 +64,8 @@ resource "helm_release" "kube_prometheus_stack" {
```

[0]: https://helm.sh/docs/chart_best_practices/custom_resource_definitions/
[2]: https://registry.terraform.io/providers/gavinbunney/kubectl/1.14.0
[3]: https://registry.terraform.io/providers/gavinbunney/kubectl/latest/docs#configuration
[2]: https://registry.terraform.io/providers/alekc/kubectl/latest/docs
[3]: https://registry.terraform.io/providers/alekc/kubectl/latest/docs#configuration
[4]: https://github.com/prometheus-community/helm-charts/blob/main/charts/kube-prometheus-stack/README.md
[5]: https://registry.terraform.io/providers/hashicorp/helm/latest/docs
[6]: https://registry.terraform.io/modules/rpadovani/helm-crds/kubectl/latest?tab=inputs
5 changes: 4 additions & 1 deletion versions.tf
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
terraform {
required_version = ">= 0.13"

required_providers {
kubectl = {
source = "gavinbunney/kubectl"
source = "alekc/kubectl"
version = "~> 2.0"
}
}
}

0 comments on commit f176b90

Please sign in to comment.