projectsyn / component-prometheus

Commodore component to wrap kube-prometheus jsonnet library.
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

CustomResourceDefinition.apiextensions.k8s.io "prometheuses.monitoring.coreos.com" is invalid: metadata.annotations: Too long: must have at most 262144 bytes #57

Closed megian closed 2 years ago

megian commented 2 years ago

Deploying the Prometheus CRD seems to be too big to apply.

The apply work if it's done via server side apply together with --force-conflicts:

The CustomResourceDefinition "prometheuses.monitoring.coreos.com" is invalid: metadata.annotations: Too long: must have at most 262144 bytes
kubectl apply -f 10_prometheusOperator_0prometheusCustomResourceDefinition.yaml --server-side --force-conflicts

Size:

-rw-r--r-- 1 user user 523K Oct 10 17:37 10_prometheusOperator_0prometheusCustomResourceDefinition.yaml

Steps to Reproduce the Problem

  1. Use Kubernetes 1.23
  2. Compile the cluster catalog
  3. Apply with ArgoCD v2.3.4

Actual Behavior

Can't be applied because of the size

Expected Behavior

Apply does work regular with ArgoCD

megian commented 2 years ago

Replacing the CRD with ArgoCD sync options: https://github.com/vmeta42/metashow/commit/1cf4f03e7592946603bc45409619d2fe877cad5a