---
apiVersion: helm.toolkit.fluxcd.io/v2beta1
kind: HelmRelease
metadata:
  name: osdu-developer-base-core
  namespace: default
  annotations:
    clusterconfig.azure.com/use-managed-source: "true"
spec:
  targetNamespace: osdu-core
  chart:
    spec:
      chart: ./charts/osdu-developer-base
      sourceRef:
        kind: GitRepository
        name: flux-system
        namespace: flux-system
  interval: 5m0s
  install:
    remediation:
      retries: 3
  valuesFrom:
    - kind: ConfigMap
      name: config-map-values
      valuesKey: values.yaml
  values:
    enableRequestAuthentication: true
    azure:
      enabled: true
    resourceLimits:
      defaultCpuRequests: "0.5"
      defaultMemoryRequests: "1Gi"
      defaultCpuLimits: "2"
      defaultMemoryLimits: "4Gi"
---
apiVersion: helm.toolkit.fluxcd.io/v2beta1
kind: HelmRelease
metadata:
  name: blob-upload
  namespace: default
  annotations:
    clusterconfig.azure.com/use-managed-source: "true"
spec:
  dependsOn:
    - name: osdu-developer-base-core
      namespace: default
  targetNamespace: osdu-core
  chart:
    spec:
      chart: ./charts/blob-upload
      sourceRef:
        kind: GitRepository
        name: flux-system
        namespace: flux-system
  interval: 5m0s
  install:
    remediation:
      retries: 3
  valuesFrom:
    - kind: ConfigMap
      name: config-map-values
      valuesKey: values.yaml
  values:
    global:
      configmapNamespace: osdu-core
    blobUpload:
      enabled: true
      items:
        - name: legal
          file: "Legal_COO.json"
          url: "https://raw.githubusercontent.com/Azure/osdu-developer/refs/heads/main/bicep/modules/deploy-scripts/Legal_COO.json"
