{{- if .Values.headscale.enabled }}
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
  name: headscale
  namespace: argocd
spec:
  project: default
  destination:
    server: https://kubernetes.default.svc
    namespace: headscale
  sources:
  - repoURL: https://charts.gabe565.com
    targetRevision: 0.16.0
    chart: headscale
    helm:
      valueFiles:
        - $values/values/headscale/values.yaml
  - repoURL: https://gitlab.com/oceanbox/manifests.git
    targetRevision: main
    ref: values

{{- end }}
