---
apiVersion: kustomize.toolkit.fluxcd.io/v1beta1
kind: Kustomization
metadata:
  name: core
  namespace: flux-system
spec:
  dependsOn:
    - name: infrastructure
  interval: 1h
  sourceRef:
    kind: GitRepository
    name: openappstack
  path: ./flux2/core
  prune: true
  validation: client
  postBuild:
    substituteFrom:
      - kind: Secret
        name: oas-single-sign-on-variables
      - kind: Secret
        name: oas-oauth-variables
      - kind: Secret
        name: oas-cluster-variables
  healthChecks:
    - apiVersion: helm.toolkit.fluxcd.io/v1beta1
      kind: HelmRelease
      name: metallb
      namespace: kube-system
    - apiVersion: helm.toolkit.fluxcd.io/v1beta1
      kind: HelmRelease
      name: nginx
      namespace: oas
    - apiVersion: helm.toolkit.fluxcd.io/v1beta1
      kind: HelmRelease
      name: single-sign-on
      namespace: oas
