ArgoCD Custom Resource Definition too long

When CRD's get too lengthy, we need to use server side apply

Mon, 18 Mar 2024

Without getting too technical, these docs explain why we need to use server side apply on certain actions and the differences between a client side(regular) apply. Heres how we would use it with ArgoCD. This example deploys a redis operator instance

apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
  name: redis-operator
  namespace: argo-cd
spec:
  destination:
    namespace: databases
    server: 'https://kubernetes.default.svc'
  sources:
    - chart: redis-operator
      repoURL: 'https://ot-container-kit.github.io/helm-charts/'
      targetRevision: "0"
  project: default
  syncPolicy:
    syncOptions:
      - ServerSideApply=true # Here is where we add in the server side apply
    automated:
      prune: true
      selfHeal: true
      ```
Buy Me A CoffeeDigitalOcean Referral Badge
Loading...
Edward Beazer

Edward Beazer - I just like to build shit. Sometimes I get stuck for hours, even days while trying to figure out how to solve an issue or implement a new feature. Hope my tips and tutorials can save you some time.

DigitalOcean Referral Badge