-
Notifications
You must be signed in to change notification settings - Fork 986
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
kubernetes_manifest: Error: Failed to determine GroupVersionResource for manifest #1583
Comments
Same issue here! |
Hi! I as far as I can tell, the interpolation of First question: is the value of If yes, you have to split operations into two applies. First apply creates the module.jetstack-certmanager and the second operation creates any resources that need to interpolate values in Let me know if this advice was helpful. |
Apparently it also happens when no interpolation is used in the env
Relevant code:
Output:
|
Facing similar issues with CRDS. Our scenario
Is this something that is resolvable in this module? |
I have the same issue.
and this generates error: $> terraform plan
╷
│ Error: Failed to determine GroupVersionResource for manifest
│
│ with kubernetes_manifest.kubegres_db_postgres_postgres,
│ on postgres-cluster.tf line 33, in resource "kubernetes_manifest" "kubegres_db_postgres_postgres":
│ 33: resource "kubernetes_manifest" "kubegres_db_postgres_postgres" {
│
│ no matches for kind "Kubegres" in group "kubegres.reactive-tech.io"
╵ but when I remove/comment |
Similarly on a |
i feel same pain... my setup.
and now i see issue: |
Same issue.
|
Also experiencing the same here. |
Having the same issue, It would be easier to deploy all at once by just "allowing to skip" CRD validation! If we could get an option in the terraform resource to skip API validation for CRD that are not yet there, it would work like a charm! |
Same issue with the following configuration : resource "helm_release" "rabbit_cluster_operator" {
name = "rabbitmq-cluster-operator"
repository = "https://charts.bitnami.com/bitnami"
chart = "rabbitmq-cluster-operator"
}
resource "kubernetes_manifest" "documents_rabbitmq_operator" {
depends_on = [helm_release.rabbit_cluster_operator]
manifest = {
"apiVersion" = "rabbitmq.com/v1beta1"
"kind" = "RabbitmqCluster"
"metadata" = {
"name" = "rabbit"
"namespace" = "default"
}
}
} It could be great to add an option to the existing |
Applying Kubernetes manifests for CRDs in the same apply as the Helm chart currently does not work in the Terraform Kubernetes provider. Attempting to do so results in failures when looking up the CRD version: https://github.com/thoughtbot/flightdeck/actions/runs/4810820017/jobs/8564458459 We can try doing this again once this issue is resolved: hashicorp/terraform-provider-kubernetes#1583 This reverts commits: - d5e8b32 - 139c284
The same issue with argocd app of apps (argoproj.io apiVersion):
If resource "kubernetes_manifest" "argocd_application" is commented and I run terraform plan / apply, everything is working. Only after that I am able to terraform plan / apply resource "kubernetes_manifest" "argocd_application". |
So, no way to disable checking of crd existing at planning phase ? |
Same issue as #1367 . Please add a 👍🏻 to that issue to prioritize the request. |
abandonned issue? |
Same issue here |
Same issue here try to not working |
So does anyone have a workaround for this issue? Thank you in advance and regards |
Would love a workaround here as I just hit this as well :( |
I'm also facing the same issue. |
Hi all, I encountered a similar problem with ClusterIssuers CRDs of Cert-manager and fixed it with HELM provider because it doesn't evaluate CRD with KubeAPI as
|
✅ In case anyone gets here and haven't yet figured it out... The way I solved this was to convert my YAML-encoded string into TF syntax, allowing for the dynamic values to enforce a dependency between resources and forcing the child resource to wait for the parent. Here's the concrete example for further understanding. I converted this resource: resource "kubernetes_manifest" "this" {
manifest = yamldecode(<<-EOF
apiVersion: external-secrets.io/v1beta1
kind: ExternalSecret
metadata:
name: pgpassword
namespace: default
spec:
data:
- remoteRef:
key: ${azurerm_key_vault_secret.this.name} # <- it fails because of this not being static value
secretKey: PGPASSWORD
refreshInterval: 1h
secretStoreRef:
kind: ClusterSecretStore
name: azure-keyvault
EOF
)
}
To this one: resource "kubernetes_manifest" "this" {
manifest = {
apiVersion = "external-secrets.io/v1beta1"
kind = "ExternalSecret"
metadata = {
name = "pgpassword"
namespace = "default"
}
spec = {
data = [
{
remoteRef = {
key = azurerm_key_vault_secret.this.name # but this succeeds cause this is expected TF syntax
}
secretKey = "PGPASSWORD"
}
]
refreshInterval = "1h"
secretStoreRef = {
kind = "ClusterSecretStore"
name = "azure-keyvault"
}
}
}
} And this solved it for me. 🚀 |
For anyone still struggling with this: consider moving all resources which install CRDs (e.g. |
When trying to deploy jetstack module as part of the aws elb module it fails as the api_group is a known after variable
Terraform Version, Provider Version and Kubernetes Version
Affected Resource(s)
Terraform Configuration Files
Debug Output
GIST
Panic Output
Steps to Reproduce
terraform apply
-->Expected Behavior
Kubernetes manifest to know a key variable is known after apply and to skip in plan
Actual Behavior
provider fails
Important Factoids
None
References
None
Community Note
The text was updated successfully, but these errors were encountered: