Skip to content

Commit

Permalink
Merge pull request #5 from kabisa/fix/custom-resource-creation
Browse files Browse the repository at this point in the history
fix creation of CRD's
  • Loading branch information
Glaaj authored Jun 15, 2022
2 parents a4db8a3 + cc9ca1b commit 80326ff
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ No modules.
| [kubernetes_cluster_role_binding.alb_ingress_controller](https://registry.terraform.io/providers/hashicorp/kubernetes/latest/docs/resources/cluster_role_binding) | resource |
| [kubernetes_service_account.alb_ingress_controller](https://registry.terraform.io/providers/hashicorp/kubernetes/latest/docs/resources/service_account) | resource |
| [aws_iam_policy_document.policy](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/iam_policy_document) | data source |
| [kubectl_file_documents.crds](https://registry.terraform.io/providers/gavinbunney/kubectl/latest/docs/data-sources/file_documents) | data source |

## Inputs

Expand Down
7 changes: 6 additions & 1 deletion main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,13 @@ resource "aws_iam_role_policy_attachment" "alb-ingress-controller-iam-role-polic
policy_arn = aws_iam_policy.alb-ingress-controller-iam-policy.arn
}

data "kubectl_file_documents" "crds" {
content = file("${path.module}/yamls/crds.yaml")
}

resource "kubectl_manifest" "crds" {
yaml_body = file("${path.module}/yamls/crds.yaml")
for_each = data.kubectl_file_documents.crds.manifests
yaml_body = each.value
}

# V 2.4.1
Expand Down

0 comments on commit 80326ff

Please sign in to comment.