Deploy with ArgoCD - Administrator Guide - Cortex CLOUD

KSPM-Documentation

Product
Cortex Cloud Application Security > Cortex CLOUD
Creation date
2025-05-11
Last date published
2026-06-11
Category
Administrator Guide

Deploy the Cortex KSPM agent to on-premises Kubernetes clusters using ArgoCD. ArgoCD is a declarative GitOps continuous delivery tool that automates agent deployment and configuration synchronization from a Git repository.

  1. Install ArgoCD.

    kubectl create namespace argocd
    kubectl apply -n argocd -f https://raw.githubusercontent.com/argoproj/argo-cd/stable/manifests/install.yaml
  2. Connect ArgoCD to a git repository.

    # HTTPS based authentication
    cat <<EOF | kubectl apply -f -
    apiVersion: v1
    kind: Secret
    metadata:
      name: gitlab-repo
      namespace: argocd
      labels:
        argocd.argoproj.io/secret-type: repository
    stringData:
      type: git
      url: https://gitlab.example.com/kspm/kspm-gitops.git
      username: <GIT_USERNAME>
      password: <GIT_TOKEN>
    EOF
    
    # SSH based authentication
    cat <<EOF | kubectl apply -f -
    apiVersion: v1
    kind: Secret
    metadata:
      name: gitlab-repo
      namespace: argocd
      labels:
        argocd.argoproj.io/secret-type: repository
    stringData:
      type: git
      url: git@gitlab.example.com:kspm/kspm-gitops.git
      sshPrivateKey: |
        -----BEGIN OPENSSH PRIVATE KEY-----
        <your-private-key>
        -----END OPENSSH PRIVATE KEY-----
    EOF
  3. Apply the ArgoCD Application manifest.

    kubectl apply -f charts/overlays/application.yaml