# Default values for flowise.
# This is a YAML-formatted file.
# Declare variables to be passed into your templates.

## @section Global parameters

global:
  ## @param global.imageRegistry Global Docker image registry
  imageRegistry: ""

  ## @param global.imagePullSecrets Global Docker registry secret names as an array
  imagePullSecrets: []

## @section Common parameters

## @param kubeVersion Override Kubernetes version
kubeVersion: ""

## @param nameOverride Partially override `flowise.fullname` template with a string (will prepend the release name)
nameOverride: ""

## @param fullnameOverride Fully override `flowise.fullname` template with a string
fullnameOverride: ""

## @param namespaceOverride Fully override `common.names.namespace` template with a string
namespaceOverride: ""

## @param commonAnnotations Annotations to add to all deployed objects
commonAnnotations: {}

## @param commonLabels Labels to add to all deployed objects
commonLabels: {}

## @param extraDeploy Array of extra objects to deploy with the release
extraDeploy: []

## @section Parameters

## @param replicaCount Number of replicas (do not change it)
replicaCount: 1

## @param revisionHistoryLimit Number of old history to retain to allow rollback
revisionHistoryLimit: 10

updateStrategy:
  ## @param updateStrategy.type Update strategy type (do not change it)
  type: Recreate

image:
  ## @param image.registry Image registry
  registry: docker.io

  ## @param image.repository Image repository
  repository: flowiseai/flowise

  ## @param image.tag Image tag
  tag: 3.0.3

  ## @param image.digest Image digest
  digest: ""

  ## @param image.pullPolicy Image pull policy
  pullPolicy: IfNotPresent

pdb:
  ## @param pdb.create Specifies whether a pod disruption budget should be created
  create: false

  ## @param pdb.minAvailable Minimum number/percentage of pods that should remain scheduled
  minAvailable: 1

  ## @param pdb.maxUnavailable Maximum number/percentage of pods that may be made unavailable
  maxUnavailable:
  # maxUnavailable: 1

serviceAccount:
  ## @param serviceAccount.create Specifies whether a service account should be created
  create: true

  ## @param serviceAccount.annotations Service account annotations
  annotations: {}

  ## @param serviceAccount.name The name of the service account to use (Generated using the `flowise.fullname` template if not set)
  name:

## @param enableServiceLinks Whether information about services should be injected into pod's environment variable
enableServiceLinks: false

## @param hostAliases Pod host aliases
hostAliases: []

## @param deploymentAnnotations Additional deployment annotations
deploymentAnnotations: {}

## @param podAnnotations Additional pod annotations
podAnnotations: {}

## @param podLabels Additional pod labels
podLabels: {}

## @extra podSecurityContext Pod security context
## @param podSecurityContext.seccompProfile.type Set pod's Security Context seccomp profile
podSecurityContext:
  seccompProfile:
    type: RuntimeDefault

## @param priorityClassName Priority class name
priorityClassName:
# priorityClassName : high-priority

## @param runtimeClassName Runtime class name
runtimeClassName: ""

## @param topologySpreadConstraints Topology Spread Constraints for pod assignment
topologySpreadConstraints: []

## @extra securityContext Container security context
## @param securityContext.allowPrivilegeEscalation Set container's Security Context allowPrivilegeEscalation
## @param securityContext.capabilities.drop List of capabilities to be dropped
## @param securityContext.readOnlyRootFilesystem Set container's Security Context readOnlyRootFilesystem
## @param securityContext.runAsNonRoot Whether the container must run as a non-root user
## @param securityContext.runAsUser The UID to run the entrypoint of the container process
## @param securityContext.runAsGroup The GID to run the entrypoint of the container process
securityContext:
  allowPrivilegeEscalation: true
  capabilities:
    drop: []
  readOnlyRootFilesystem: false
  runAsNonRoot: false
  runAsUser: 0
  runAsGroup: 0

containerPorts:
  ## @param containerPorts.http Container port for HTTP
  http: 3000

livenessProbe:
  ## @param livenessProbe.enabled Enable liveness probe
  enabled: true

  ## @param livenessProbe.initialDelaySeconds Delay before the liveness probe is initiated
  initialDelaySeconds: 0

  ## @param livenessProbe.periodSeconds How often to perform the liveness probe
  periodSeconds: 10

  ## @param livenessProbe.timeoutSeconds When the liveness probe times out
  timeoutSeconds: 1

  ## @param livenessProbe.failureThreshold Minimum consecutive failures for the liveness probe to be considered failed after having succeeded
  failureThreshold: 3

  ## @param livenessProbe.successThreshold Minimum consecutive successes for the liveness probe to be considered successful after having failed
  successThreshold: 1

readinessProbe:
  ## @param readinessProbe.enabled Enable readiness probe
  enabled: true

  ## @param readinessProbe.initialDelaySeconds Delay before the readiness probe is initiated
  initialDelaySeconds: 0

  ## @param readinessProbe.periodSeconds How often to perform the readiness probe
  periodSeconds: 10

  ## @param readinessProbe.timeoutSeconds When the readiness probe times out
  timeoutSeconds: 1

  ## @param readinessProbe.failureThreshold Minimum consecutive failures for the readiness probe to be considered failed after having succeeded
  failureThreshold: 3

  ## @param readinessProbe.successThreshold Minimum consecutive successes for the readiness probe to be considered successful after having failed
  successThreshold: 1

startupProbe:
  ## @param startupProbe.enabled Enable startup probe
  enabled: false

  ## @param startupProbe.initialDelaySeconds Delay before the startup probe is initiated
  initialDelaySeconds: 0

  ## @param startupProbe.periodSeconds How often to perform the startup probe
  periodSeconds: 10

  ## @param startupProbe.timeoutSeconds When the startup probe times out
  timeoutSeconds: 1

  ## @param startupProbe.failureThreshold Minimum consecutive failures for the startup probe to be considered failed after having succeeded
  failureThreshold: 3

  ## @param startupProbe.successThreshold Minimum consecutive successes for the startup probe to be considered successful after having failed
  successThreshold: 1

service:
  ## @param service.annotations Service annotations
  annotations: {}

  ## @param service.type Service type
  type: ClusterIP

  ## @param service.clusterIP Static cluster IP address or None for headless service when service type is ClusterIP
  clusterIP:
  # clusterIP: 10.43.0.100

  ## @param service.ipFamilyPolicy Service IP family policy
  ipFamilyPolicy: ""

  ## @param service.ipFamilies Service IP families
  ipFamilies: []

  ## @param service.sessionAffinity Control where client requests go, to the same pod or round-robin
  sessionAffinity: None

  ## @param service.sessionAffinityConfig Additional settings for the sessionAffinity
  sessionAffinityConfig: {}

  ## @param service.loadBalancerIP Static load balancer IP address when service type is LoadBalancer
  loadBalancerIP:
  # loadBalancerIP: 10.0.0.100

  ## @param service.loadBalancerSourceRanges Source IP address ranges when service type is LoadBalancer
  loadBalancerSourceRanges:
    # - 10.0.0.0/24

  ## @param service.externalTrafficPolicy External traffic routing policy when service type is LoadBalancer or NodePort
  externalTrafficPolicy: Cluster

  ports:
    ## @param service.ports.http Service port for HTTP
    http: 3000

  nodePorts:
    ## @param service.nodePorts.http Service node port for HTTP when service type is LoadBalancer or NodePort
    http:
    # http: 30000

ingress:
  ## @param ingress.enabled Enable ingress controller resource
  enabled: false

  ## @param ingress.ingressClassName IngressClass that will be be used to implement the Ingress
  ingressClassName: ""

  ## @param ingress.pathType Ingress path type
  pathType: ImplementationSpecific

  ## @param ingress.annotations Ingress annotations
  annotations: {}
    # kubernetes.io/ingress.class: nginx
    # kubernetes.io/tls-acme: "true"

  ## @param ingress.hosts[0].host Hostname to your Flowise installation
  ## @param ingress.hosts[0].paths Paths within the url structure
  hosts:
    - host: flowise.local
      paths:
        - /

  ## @param ingress.tls TLS configuration
  tls: []
    # - secretName: flowise-tls
    #   hosts:
    #     - flowise.local

## @param resources CPU/Memory resource requests/limits
resources: {}
  # requests:
  #   cpu: 100m
  #   memory: 128Mi
  # limits:
  #   cpu: 100m
  #   memory: 128Mi

## @param nodeSelector Node labels for pod assignment
nodeSelector: {}

## @param tolerations Tolerations for pod assignment
tolerations: []

## @param affinity Map of node/pod affinities
affinity: {}

## @param extraArgs Additional container arguments
extraArgs: {}
  # name: ""

## @param extraEnvVars Additional container environment variables
extraEnvVars: []
  # - name: MY-NAME
  #   value: "MY-VALUE"

## @param extraEnvVarsCM Name of existing ConfigMap containing additional container environment variables
extraEnvVarsCM:

## @param extraEnvVarsSecret Name of existing Secret containing additional container environment variables
extraEnvVarsSecret:

## @param extraVolumes Optionally specify extra list of additional volumes
extraVolumes: []

## @param extraVolumeMounts Optionally specify extra list of additional volumeMounts
extraVolumeMounts: []

persistence:
  ## @param persistence.enabled Enable persistence using PVC
  enabled: false

  ## @param persistence.existingClaim Name of an existing PVC to use
  existingClaim:
  # existingClaim: my-pvc

  ## @param persistence.accessMode PVC access mode
  accessMode: ReadWriteOnce

  ## @param persistence.annotations PVC annotations
  annotations: {}

  ## @param persistence.size PVC size
  size: 1Gi

  ## @param persistence.storageClass PVC storage class
  storageClass:
  # storageClass: -

## @section Config parameters

config:
  ## @param config.mode Mode to run Flowise
  mode: main

  ## @param config.encryptionKey Encryption key
  encryptionKey: ""

## @param existingSecret Name of existing Secret to use
existingSecret: ""

## @param existingSecretKeyEncryptionKey Key in existing Secret that contains encryption key
existingSecretKeyEncryptionKey: encryption-key

## @section Worker parameters

worker:
  ## @param worker.enabled Enable the component
  enabled: false

  ## @param worker.replicaCount Number of replicas
  replicaCount: 1

  ## @param worker.revisionHistoryLimit Number of old history to retain to allow rollback
  revisionHistoryLimit: 10

  image:
    ## @param worker.image.registry Image registry
    registry: docker.io

    ## @param worker.image.repository Image repository
    repository: flowiseai/flowise-worker

    ## @param worker.image.tag Image tag
    tag: 3.0.3

    ## @param worker.image.digest Image digest
    digest: ""

    ## @param worker.image.pullPolicy Image pull policy
    pullPolicy: IfNotPresent

  pdb:
    ## @param worker.pdb.create Specifies whether a pod disruption budget should be created
    create: false

    ## @param worker.pdb.minAvailable Minimum number/percentage of pods that should remain scheduled
    minAvailable: 1

    ## @param worker.pdb.maxUnavailable Maximum number/percentage of pods that may be made unavailable
    maxUnavailable:
    # maxUnavailable: 1

  serviceAccount:
    ## @param worker.serviceAccount.create Specifies whether a service account should be created
    create: true

    ## @param worker.serviceAccount.annotations Service account annotations
    annotations: {}

    ## @param worker.serviceAccount.name The name of the service account to use (Generated using the `flowise.fullname` template if not set)
    name:

  ## @param worker.enableServiceLinks Whether information about services should be injected into pod's environment variable
  enableServiceLinks: false

  ## @param worker.hostAliases Pod host aliases
  hostAliases: []

  ## @param worker.deploymentAnnotations Additional deployment annotations
  deploymentAnnotations: {}

  ## @param worker.podAnnotations Additional pod annotations
  podAnnotations: {}

  ## @param worker.podLabels Additional pod labels
  podLabels: {}

  ## @extra worker.podSecurityContext Pod security context
  ## @param worker.podSecurityContext.seccompProfile.type Set pod's Security Context seccomp profile
  podSecurityContext:
    seccompProfile:
      type: RuntimeDefault

  ## @param worker.priorityClassName Priority class name
  priorityClassName:
  # priorityClassName : high-priority

  ## @param worker.runtimeClassName Runtime class name
  runtimeClassName: ""

  ## @param worker.topologySpreadConstraints Topology Spread Constraints for pod assignment
  topologySpreadConstraints: []

  ## @extra worker.securityContext Container security context
  ## @param worker.securityContext.allowPrivilegeEscalation Set container's Security Context allowPrivilegeEscalation
  ## @param worker.securityContext.capabilities.drop List of capabilities to be dropped
  ## @param worker.securityContext.readOnlyRootFilesystem Set container's Security Context readOnlyRootFilesystem
  ## @param worker.securityContext.runAsNonRoot Whether the container must run as a non-root user
  ## @param worker.securityContext.runAsUser The UID to run the entrypoint of the container process
  ## @param worker.securityContext.runAsGroup The GID to run the entrypoint of the container process
  securityContext:
    allowPrivilegeEscalation: true
    capabilities:
      drop: []
    readOnlyRootFilesystem: false
    runAsNonRoot: false
    runAsUser: 0
    runAsGroup: 0

  containerPorts:
    ## @param worker.containerPorts.probes Container port for Probes
    probes: 5566

  livenessProbe:
    ## @param worker.livenessProbe.enabled Enable liveness probe
    enabled: true

    ## @param worker.livenessProbe.initialDelaySeconds Delay before the liveness probe is initiated
    initialDelaySeconds: 0

    ## @param worker.livenessProbe.periodSeconds How often to perform the liveness probe
    periodSeconds: 10

    ## @param worker.livenessProbe.timeoutSeconds When the liveness probe times out
    timeoutSeconds: 1

    ## @param worker.livenessProbe.failureThreshold Minimum consecutive failures for the liveness probe to be considered failed after having succeeded
    failureThreshold: 3

    ## @param worker.livenessProbe.successThreshold Minimum consecutive successes for the liveness probe to be considered successful after having failed
    successThreshold: 1

  readinessProbe:
    ## @param worker.readinessProbe.enabled Enable readiness probe
    enabled: true

    ## @param worker.readinessProbe.initialDelaySeconds Delay before the readiness probe is initiated
    initialDelaySeconds: 0

    ## @param worker.readinessProbe.periodSeconds How often to perform the readiness probe
    periodSeconds: 10

    ## @param worker.readinessProbe.timeoutSeconds When the readiness probe times out
    timeoutSeconds: 1

    ## @param worker.readinessProbe.failureThreshold Minimum consecutive failures for the readiness probe to be considered failed after having succeeded
    failureThreshold: 3

    ## @param worker.readinessProbe.successThreshold Minimum consecutive successes for the readiness probe to be considered successful after having failed
    successThreshold: 1

  startupProbe:
    ## @param worker.startupProbe.enabled Enable startup probe
    enabled: false

    ## @param worker.startupProbe.initialDelaySeconds Delay before the startup probe is initiated
    initialDelaySeconds: 0

    ## @param worker.startupProbe.periodSeconds How often to perform the startup probe
    periodSeconds: 10

    ## @param worker.startupProbe.timeoutSeconds When the startup probe times out
    timeoutSeconds: 1

    ## @param worker.startupProbe.failureThreshold Minimum consecutive failures for the startup probe to be considered failed after having succeeded
    failureThreshold: 3

    ## @param worker.startupProbe.successThreshold Minimum consecutive successes for the startup probe to be considered successful after having failed
    successThreshold: 1

  ## @param worker.resources CPU/Memory resource requests/limits
  resources: {}
    # requests:
    #   cpu: 100m
    #   memory: 128Mi
    # limits:
    #   cpu: 100m
    #   memory: 128Mi

  ## @param worker.nodeSelector Node labels for pod assignment
  nodeSelector: {}

  ## @param worker.tolerations Tolerations for pod assignment
  tolerations: []

  ## @param worker.affinity Map of node/pod affinities
  affinity: {}

  ## @param worker.extraArgs Additional container arguments
  extraArgs: {}
    # name: ""

  ## @param worker.extraEnvVars Additional container environment variables
  extraEnvVars: []
    # - name: MY-NAME
    #   value: "MY-VALUE"

  ## @param worker.extraEnvVarsCM Name of existing ConfigMap containing additional container environment variables
  extraEnvVarsCM:

  ## @param worker.extraEnvVarsSecret Name of existing Secret containing additional container environment variables
  extraEnvVarsSecret:

  ## @param worker.extraVolumes Optionally specify extra list of additional volumes
  extraVolumes: []

  ## @param worker.extraVolumeMounts Optionally specify extra list of additional volumeMounts
  extraVolumeMounts: []

## @section MariaDB parameters

mariadb:
  ## @param mariadb.enabled Whether to use the MariaDB chart
  enabled: false

  ## @param mariadb.architecture MariaDB architecture
  architecture: standalone

  auth:
    ## @param mariadb.auth.database MariaDB database
    database: flowise

    ## @param mariadb.auth.username MariaDB user
    username: flowise

    ## @param mariadb.auth.password MariaDB password
    password: flowise

    ## @param mariadb.auth.existingSecret Name of existing Secret to use
    existingSecret: ""

  primary:
    service:
      ports:
        ## @param mariadb.primary.service.ports.mysql MariaDB port
        mysql: 3306

externalMariadb:
  ## @param externalMariadb.enabled Whether to use an external MariaDB
  enabled: false

  ## @param externalMariadb.host External MariaDB host
  host: mariadb

  ## @param externalMariadb.port External MariaDB port
  port: 3306

  ## @param externalMariadb.username External MariaDB user
  username: flowise

  ## @param externalMariadb.password External MariaDB password
  password: flowise

  ## @param externalMariadb.existingSecret Name of existing Secret to use
  existingSecret: ""

  ## @param externalMariadb.existingSecretKeyPassword Key in existing Secret that contains MariaDB password
  existingSecretKeyPassword: mariadb-password

  ## @param externalMariadb.database External MariaDB database
  database: flowise

## @section PostgreSQL parameters

postgresql:
  ## @param postgresql.enabled Whether to use the PostgreSQL chart
  enabled: false

  auth:
    ## @param postgresql.auth.username PostgreSQL user
    username: flowise

    ## @param postgresql.auth.password PostgreSQL password
    password: flowise

    ## @param postgresql.auth.database PostgreSQL database
    database: flowise

    ## @param postgresql.auth.existingSecret Name of existing Secret to use
    existingSecret: ""

  ## @param postgresql.architecture PostgreSQL architecture
  architecture: standalone

  primary:
    service:
      ports:
        ## @param postgresql.primary.service.ports.postgresql PostgreSQL port
        postgresql: 5432

externalPostgresql:
  ## @param externalPostgresql.enabled Whether to use an external PostgreSQL
  enabled: false

  ## @param externalPostgresql.host External PostgreSQL host
  host: postgresql

  ## @param externalPostgresql.port External PostgreSQL port
  port: 5432

  ## @param externalPostgresql.username External PostgreSQL user
  username: flowise

  ## @param externalPostgresql.password External PostgreSQL password
  password: flowise

  ## @param externalPostgresql.existingSecret Name of existing Secret to use
  existingSecret: ""

  ## @param externalPostgresql.existingSecretKeyPassword Key in existing Secret that contains PostgreSQL password
  existingSecretKeyPassword: password

  ## @param externalPostgresql.database External PostgreSQL database
  database: flowise

## @section Redis parameters

redis:
  ## @param redis.enabled Whether to use the Redis chart
  enabled: false

  ## @param redis.architecture Redis architecture
  architecture: standalone

  auth:
    ## @param redis.auth.password Redis password
    password: flowise

    ## @param redis.auth.existingSecret Name of existing Secret to use
    existingSecret: ""

  master:
    service:
      ports:
        ## @param redis.master.service.ports.redis Redis port
        redis: 6379

externalRedis:
  ## @param externalRedis.enabled Whether to use an external Redis
  enabled: false

  ## @param externalRedis.host External Redis host
  host: redis

  ## @param externalRedis.port External Redis port
  port: 6379

  ## @param externalRedis.password External Redis password
  password: flowise

  ## @param externalRedis.existingSecret Name of existing Secret to use
  existingSecret: ""

  ## @param externalRedis.existingSecretKeyPassword Key in existing Secret that contains Redis password
  existingSecretKeyPassword: redis-password

## @section Wait parameters

wait:
  image:
    ## @param wait.image.registry Image registry
    registry: docker.io

    ## @param wait.image.repository Image repository
    repository: wait4x/wait4x

    ## @param wait.image.tag Image tag
    tag: 3.3.1

    ## @param wait.image.digest Image digest
    digest: ""

    ## @param wait.image.pullPolicy Image pull policy
    pullPolicy: IfNotPresent

  ## @extra wait.securityContext Container security context
  ## @param wait.securityContext.allowPrivilegeEscalation Set container's Security Context allowPrivilegeEscalation
  ## @param wait.securityContext.capabilities.drop List of capabilities to be dropped
  ## @param wait.securityContext.readOnlyRootFilesystem Set container's Security Context readOnlyRootFilesystem
  ## @param wait.securityContext.runAsNonRoot Whether the container must run as a non-root user
  ## @param wait.securityContext.runAsUser The UID to run the entrypoint of the container process
  ## @param wait.securityContext.runAsGroup The GID to run the entrypoint of the container process
  securityContext:
    allowPrivilegeEscalation: false
    capabilities:
      drop:
        - ALL
    readOnlyRootFilesystem: true
    runAsNonRoot: true
    runAsUser: 65534
    runAsGroup: 65534

  ## @param wait.resources CPU/Memory resource requests/limits
  resources: {}
    # requests:
    #   cpu: 100m
    #   memory: 128Mi
    # limits:
    #   cpu: 100m
    #   memory: 128Mi

  ## @param wait.extraVolumeMounts Optionally specify extra list of additional volumeMounts
  extraVolumeMounts: []

## @section Tests parameters

tests:
  image:
    ## @param tests.image.registry Image registry
    registry: ghcr.io

    ## @param tests.image.repository Image repository
    repository: cowboysysop/pytest

    ## @param tests.image.tag Image tag
    tag: 1.2.0

    ## @param tests.image.digest Image digest
    digest: ""

    ## @param tests.image.pullPolicy Image pull policy
    pullPolicy: IfNotPresent
