{{- if index .Values "argo-cd" "kubezero" "bootstrap" }}
apiVersion: argoproj.io/v1alpha1
kind: AppProject
metadata:
  name: kubezero
  namespace: argocd
  labels:
    {{- include "kubezero-lib.labels" . | nindent 4 }}
spec:
  clusterResourceWhitelist:
  - group: '*'
    kind: '*'
  description: KubeZero - ZeroDownTime Kubernetes Platform
  destinations:
  - namespace: '*'
    server: https://kubernetes.default.svc
  sourceRepos:
  - https://cdn.zero-downtime.net/charts
  - {{ index .Values "argo-cd" "kubezero" "repoUrl" }}
  syncWindows:
    - kind: deny
      schedule: '0 * * * *'
      duration: 24h
      namespaces:
      - '*'
{{- end }}
