/argocd-typescript-plugin

argocd-typescript extends the capabilities of ArgoCD by integrating Node.js and TypeScript. Elevate your ArgoCD experience with the power of Node.js and the expressiveness of TypeScript in managing and deploying your applications seamlessly.

Primary LanguageDockerfile

Argocd cdk8s

Pre-requisites

Setup ArgoCD

Assume that you're going to install Argocd with Helm. You may need to override the default values of the ArgoCD chart. For example,

# values.yaml
global:
  image:
    repository: 'softnetics/argocd-cdk8s'
    tag: '1.0.0' # Recheck the latest tag

After that, install the ArgoCD with the following command.

helm repo add argo https://argoproj.github.io/argo-helm
helm install argocd argo/argo-cd -f values.yaml

Then, add the ArgoCD ConfigManagementPlugin after the ArgoCD installation.

# plugin.yaml
apiVersion: argoproj.io/v1alpha1
kind: ConfigManagementPlugin
metadata:
  name: argocd-cdk8s-plugin
spec:
  version: v1.0
  init:
    command: [sh]
    args: ['-c', 'cdk8s synth']
  generate:
    command: [sh]
    args: ['-c', 'cat dist/*']
  # The plugin will be executed if and only if there's `main.ts` file in the root of the source directory.
  discover:
    fileName: './main.ts'

Finally, apply the plugin to the ArgoCD.

kubectl apply -f plugin.yaml

References

Thank you for the following resources: