Skip to content

Commit

Permalink
feat: reimplement storage class with hashicorp/kubernetes provider
Browse files Browse the repository at this point in the history
  • Loading branch information
Abel Garcia Dorta committed Dec 1, 2021
1 parent b23f55f commit bf1a588
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 14 deletions.
17 changes: 7 additions & 10 deletions storage-class.tf
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@
resource "kubectl_manifest" "storage_class" {
resource "kubernetes_storage_class" "storage_class" {
count = (var.enabled && var.create_storage_class) ? 1 : 0
yaml_body = <<YAML
kind: StorageClass
apiVersion: storage.k8s.io/v1
metadata:
name: ${var.storage_class_name}
provisioner: efs.csi.aws.com
YAML
depends_on = [helm_release.kubernetes_efs_csi_driver]
}
metadata {
name = var.storage_class_name
}
storage_provisioner = "efs.csi.aws.com"
depends_on = [helm_release.kubernetes_efs_csi_driver]
}
4 changes: 0 additions & 4 deletions versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,5 @@ terraform {
aws = ">= 3.13, < 4.0"
helm = ">= 1.0, < 3.0"
kubernetes = ">= 1.10.0, < 3.0.0"
kubectl = {
source = "gavinbunney/kubectl"
version = ">= 1.9.4"
}
}
}

0 comments on commit bf1a588

Please sign in to comment.