apiVersion: helm.toolkit.fluxcd.io/v2beta2
kind: HelmRelease
metadata:
  name: pgadmin4
  namespace: database
spec:
  interval: 5m
  chart:
    spec:
      chart: pgadmin4
      version: "1.23.1"
      sourceRef:
        kind: HelmRepository
        name: runix-charts
        namespace: flux-system
  values:
    ingress:
      enabled: true
      annotations:
        cert-manager.io/cluster-issuer: letsencrypt-production
        traefik.ingress.kubernetes.io/router.entrypoints: websecure
      hosts:
        - host: &host pgadm.${SECRET_NEW_DOMAIN}
          paths:
            - path: "/"
              pathType: Prefix
      tls:
        - hosts:
            - *host

#    securityContext:
#      runAsUser: 10000
#      runAsGroup: 10000
#      fsGroup: 10000
#
#    containerSecurityContext:
#      enabled: true
#      allowPrivilegeEscalation: false

#    envVarsFromConfigMaps:
#    - pgadmin4-secret

    persistentVolume:
      enabled: false

    volumePermissions:
      enabled: true