diff --git a/bitnami/argo-workflows/.helmignore b/bitnami/argo-workflows/.helmignore new file mode 100644 index 000000000..0e8a0eb36 --- /dev/null +++ b/bitnami/argo-workflows/.helmignore @@ -0,0 +1,23 @@ +# Patterns to ignore when building packages. +# This supports shell glob matching, relative path matching, and +# negation (prefixed with !). Only one pattern per line. +.DS_Store +# Common VCS dirs +.git/ +.gitignore +.bzr/ +.bzrignore +.hg/ +.hgignore +.svn/ +# Common backup files +*.swp +*.bak +*.tmp +*.orig +*~ +# Various IDEs +.project +.idea/ +*.tmproj +.vscode/ diff --git a/bitnami/argo-workflows/Chart.lock b/bitnami/argo-workflows/Chart.lock new file mode 100644 index 000000000..20d183325 --- /dev/null +++ b/bitnami/argo-workflows/Chart.lock @@ -0,0 +1,12 @@ +dependencies: +- name: postgresql + repository: https://charts.bitnami.com/bitnami + version: 10.12.0 +- name: mysql + repository: https://charts.bitnami.com/bitnami + version: 8.8.8 +- name: common + repository: https://charts.bitnami.com/bitnami + version: 1.10.0 +digest: sha256:b87222b0f105266f7fda393730fe18a18347c6690a9afffd91224b6f5231a683 +generated: "2021-10-01T12:27:54.621180431Z" diff --git a/bitnami/argo-workflows/Chart.yaml b/bitnami/argo-workflows/Chart.yaml new file mode 100644 index 000000000..83646c217 --- /dev/null +++ b/bitnami/argo-workflows/Chart.yaml @@ -0,0 +1,38 @@ +annotations: + category: Infrastructure +apiVersion: v2 +appVersion: 3.1.10 +dependencies: + - condition: postgresql.enabled + name: postgresql + repository: https://charts.bitnami.com/bitnami + version: 10.x.x + - condition: mysql.enabled + name: mysql + repository: https://charts.bitnami.com/bitnami + version: 8.x.x + - name: common + repository: https://charts.bitnami.com/bitnami + tags: + - bitnami-common + version: 1.x.x +description: Argo Workflows is meant to orchestrate Kubernetes jobs in parallel +engine: gotpl +home: https://argoproj.github.io/workflows/ +icon: https://bitnami.com/assets/stacks/argo-workflow-cli/img/argo-workflow-cli-stack-220x234.png +keywords: + - Devops + - Kubernetes + - Jobs + - Continuous delivery + - Continous deployment +maintainers: + - email: containers@bitnami.com + name: Bitnami +name: argo-workflows +sources: + - https://github.com/bitnami/bitnami-docker-argo-workflow-cli + - https://github.com/bitnami/bitnami-docker-argo-workflow-controller + - https://github.com/bitnami/bitnami-docker-argo-workflow-exec + - https://argoproj.github.io/workflows/ +version: 0.1.0 diff --git a/bitnami/argo-workflows/README.md b/bitnami/argo-workflows/README.md new file mode 100644 index 000000000..ed69c0fed --- /dev/null +++ b/bitnami/argo-workflows/README.md @@ -0,0 +1,451 @@ +# Argo Workflows Chart packaged by Bitnami + +[Argo Workflows](https://argoproj.github.io/workflows) allows to orchestrate parallel jobs in kubernetes. + +## TL;DR + +```console +$ helm repo add bitnami https://charts.bitnami.com/bitnami +$ helm install my-release bitnami/argo-workflows +``` + +## Introduction + +This chart bootstraps a [Argo Workflows](https://argoproj.github.io/workflows) deployment on a [Kubernetes](http://kubernetes.io) cluster using the [Helm](https://helm.sh) package manager. + +Bitnami charts can be used with [Kubeapps](https://kubeapps.com/) for deployment and management of Helm Charts in clusters. This chart has been tested to work with NGINX Ingress, cert-manager, fluentd and Prometheus on top of the [BKPR](https://kubeprod.io/). + +## Prerequisites + +- Kubernetes 1.12+ +- Helm 3.1.0 +- PV provisioner support in the underlying infrastructure +- ReadWriteMany volumes for deployment scaling + +## Installing the Chart + +To install the chart with the release name `my-release`: + +```console +helm install my-release bitnami/argo-workflowss +``` + +The command deploys Argo Workflows on the Kubernetes cluster in the default configuration. The [Parameters](#parameters) section lists the parameters that can be configured during installation. + +> **Tip**: List all releases using `helm list` + +## Uninstalling the Chart + +To uninstall/delete the `my-release` deployment: + +```console +helm delete my-release +``` + +The command removes all the Kubernetes components associated with the chart and deletes the release. + +## Parameters + +### Global parameters + +| Name | Description | Value | +| ------------------------- | ----------------------------------------------- | ----- | +| `global.imageRegistry` | Global Docker image registry | `""` | +| `global.imagePullSecrets` | Global Docker registry secret names as an array | `[]` | +| `global.storageClass` | Global StorageClass for Persistent Volume(s) | `""` | + + +### Common parameters + +| Name | Description | Value | +| ---------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------- | +| `kubeVersion` | Override Kubernetes version | `""` | +| `nameOverride` | String to partially override common.names.fullname | `""` | +| `fullnameOverride` | String to fully override common.names.fullname | `""` | +| `commonLabels` | Labels to add to all deployed objects | `{}` | +| `commonAnnotations` | Annotations to add to all deployed objects | `{}` | +| `clusterDomain` | Kubernetes cluster domain name | `cluster.local` | +| `extraDeploy` | Array of extra objects to deploy with the release | `[]` | +| `rbac.singleNamespace` | Restrict Argo to only deploy into a single namespace by apply Roles and RoleBindings instead of the Cluster equivalents, and start argo-cli with the --namespaced flag. Use it in clusters with strict access policy. | `false` | +| `createAggregateRoles` | Create Aggregated cluster roles | `true` | + + +### Argo Workflows Server configuration parameters + +| Name | Description | Value | +| ---------------------------------------------------- | ------------------------------------------------------------------------------------------------------- | --------------------------- | +| `server.image.registry` | server image registry | `docker.io` | +| `server.image.repository` | server image repository | `bitnami/argo-workflow-cli` | +| `server.image.tag` | server image tag (immutable tags are recommended) | `3.1.13-scratch-r0` | +| `server.image.pullPolicy` | server image pull policy | `Always` | +| `server.image.pullSecrets` | server image pull secrets | `[]` | +| `server.enabled` | Enable server deployment | `true` | +| `server.replicaCount` | Number of server replicas to deploy | `1` | +| `server.livenessProbe.enabled` | Enable livenessProbe on server nodes | `true` | +| `server.livenessProbe.initialDelaySeconds` | Initial delay seconds for livenessProbe | `10` | +| `server.livenessProbe.periodSeconds` | Period seconds for livenessProbe | `20` | +| `server.livenessProbe.timeoutSeconds` | Timeout seconds for livenessProbe | `1` | +| `server.livenessProbe.failureThreshold` | Failure threshold for livenessProbe | `3` | +| `server.livenessProbe.successThreshold` | Success threshold for livenessProbe | `1` | +| `server.readinessProbe.enabled` | Enable readinessProbe on server nodes | `true` | +| `server.readinessProbe.initialDelaySeconds` | Initial delay seconds for readinessProbe | `10` | +| `server.readinessProbe.periodSeconds` | Period seconds for readinessProbe | `20` | +| `server.readinessProbe.timeoutSeconds` | Timeout seconds for readinessProbe | `1` | +| `server.readinessProbe.failureThreshold` | Failure threshold for readinessProbe | `3` | +| `server.readinessProbe.successThreshold` | Success threshold for readinessProbe | `1` | +| `server.startupProbe.enabled` | Enable startupProbe | `false` | +| `server.startupProbe.path` | Path to check for startupProbe | `/` | +| `server.startupProbe.initialDelaySeconds` | Initial delay seconds for startupProbe | `300` | +| `server.startupProbe.periodSeconds` | Period seconds for startupProbe | `10` | +| `server.startupProbe.timeoutSeconds` | Timeout seconds for startupProbe | `5` | +| `server.startupProbe.failureThreshold` | Failure threshold for startupProbe | `6` | +| `server.startupProbe.successThreshold` | Success threshold for startupProbe | `1` | +| `server.customLivenessProbe` | Server custom livenessProbe that overrides the default one | `{}` | +| `server.customReadinessProbe` | Server custom readinessProbe that overrides the default one | `{}` | +| `server.customStartupProbe` | Server custom startupProbe that overrides the default one | `{}` | +| `server.resources.limits` | The resources limits for the server containers | `{}` | +| `server.resources.requests` | The requested resources for the server containers | `{}` | +| `server.podSecurityContext.enabled` | Enabled server pods' Security Context | `true` | +| `server.podSecurityContext.fsGroup` | Set server pod's Security Context fsGroup | `1001` | +| `server.containerSecurityContext.enabled` | Enabled server containers' Security Context | `true` | +| `server.containerSecurityContext.runAsUser` | Set server containers' Security Context runAsUser | `1001` | +| `server.containerSecurityContext.runAsNonRoot` | Set server containers' Security Context runAsNonRoot | `true` | +| `server.rbac.create` | Create RBAC resources for the Argo workflows server | `true` | +| `server.extraArgs` | Extra arguments for the server command line | `""` | +| `server.auth.enabled` | Enable authentication | `true` | +| `server.auth.mode` | Set authentication mode. Either `server`, `client` or `sso`. | `client` | +| `server.auth.sso.enabled` | Enable SSO configuration for the server auth mode | `false` | +| `server.auth.sso.issuer` | Root URL for the OIDC identity provider | `""` | +| `server.auth.sso.clientId.name` | Name of the secret containing the OIDC client ID | `""` | +| `server.auth.sso.clientId.key` | Key in the secret to obtain the OIDC client ID | `""` | +| `server.auth.sso.clientSecret.name` | Name of the secret containing the OIDC client secret | `""` | +| `server.auth.sso.clientSecret.key` | Key in the secret to obtain the OIDC client secret | `""` | +| `server.auth.sso.redirectUrl` | The OIDC redirect URL. Should be in the form /oauth2/callback. | `""` | +| `server.auth.sso.rbac.enabled` | Create RBAC resources for SSO | `true` | +| `server.auth.sso.rbac.secretWhitelist` | Restricts the secrets that the server can read | `[]` | +| `server.auth.sso.scopes` | Scopes requested from the SSO ID provider | `[]` | +| `server.clusterWorkflowTemplates.enabled` | Create ClusterRole and CRB for the controoler to access ClusterWorkflowTemplates | `true` | +| `server.clusterWorkflowTemplates.enableEditing` | Give the server permissions to edit ClusterWorkflowTemplates | `true` | +| `server.pdb.enabled` | Create Pod Disruption Budget for the server component | `false` | +| `server.pdb.minAvailable` | Sets the min number of pods availables for the Pod Disruption Budget | `1` | +| `server.pdb.maxUnavailable` | Sets the max number of pods unavailable for the Pod Disruption Budget | `1` | +| `server.secure` | Run Argo server in secure mode | `false` | +| `server.baseHref` | Base href of the Argo Workflows deployment | `/` | +| `server.containerPorts.web` | argo Server container port | `2746` | +| `server.serviceAccount.create` | Specifies whether a ServiceAccount should be created | `true` | +| `server.serviceAccount.name` | The name of the ServiceAccount to use. | `""` | +| `server.serviceAccount.automountServiceAccountToken` | Automount service account token for the server service account | `true` | +| `server.command` | Override default container command (useful when using custom images) | `[]` | +| `server.args` | Override default container args (useful when using custom images) | `[]` | +| `server.hostAliases` | server pods host aliases | `[]` | +| `server.podLabels` | Extra labels for server pods | `{}` | +| `server.podAnnotations` | Annotations for server pods | `{}` | +| `server.podAffinityPreset` | Pod affinity preset. Ignored if `server.affinity` is set. Allowed values: `soft` or `hard` | `""` | +| `server.podAntiAffinityPreset` | Pod anti-affinity preset. Ignored if `server.affinity` is set. Allowed values: `soft` or `hard` | `soft` | +| `server.nodeAffinityPreset.type` | Node affinity preset type. Ignored if `server.affinity` is set. Allowed values: `soft` or `hard` | `""` | +| `server.nodeAffinityPreset.key` | Node label key to match. Ignored if `server.affinity` is set | `""` | +| `server.nodeAffinityPreset.values` | Node label values to match. Ignored if `server.affinity` is set | `[]` | +| `server.affinity` | Affinity for server pods assignment | `{}` | +| `server.nodeSelector` | Node labels for server pods assignment | `{}` | +| `server.tolerations` | Tolerations for server pods assignment | `[]` | +| `server.updateStrategy.type` | server statefulset strategy type | `RollingUpdate` | +| `server.topologySpreadConstraints` | Topology spread constraints rely on node labels to identify the topology domain(s) that each Node is in | `[]` | +| `server.schedulerName` | Alternate scheduler for the server deployment | `""` | +| `server.priorityClassName` | server pods' priorityClassName | `""` | +| `server.lifecycleHooks` | for the server container(s) to automate configuration before or after startup | `{}` | +| `server.extraEnvVars` | Array with extra environment variables to add to server nodes | `[]` | +| `server.extraEnvVarsCM` | Name of existing ConfigMap containing extra env vars for server nodes | `""` | +| `server.extraEnvVarsSecret` | Name of existing Secret containing extra env vars for server nodes | `""` | +| `server.extraVolumes` | Optionally specify extra list of additional volumes for the server pod(s) | `[]` | +| `server.extraVolumeMounts` | Optionally specify extra list of additional volumeMounts for the server container(s) | `[]` | +| `server.sidecars` | Add additional sidecar containers to the server pod(s) | `{}` | +| `server.initContainers` | Add additional init containers to the server pod(s) | `{}` | +| `server.service.type` | server service type | `ClusterIP` | +| `server.service.ports.http` | server service HTTP port | `80` | +| `server.service.nodePorts.http` | Node port for HTTP | `""` | +| `server.service.clusterIP` | server service Cluster IP | `""` | +| `server.service.loadBalancerIP` | server service Load Balancer IP | `""` | +| `server.service.loadBalancerSourceRanges` | server service Load Balancer sources | `[]` | +| `server.service.externalTrafficPolicy` | server service external traffic policy | `Cluster` | +| `server.service.annotations` | Additional custom annotations for server service | `{}` | +| `server.service.extraPorts` | Extra port to expose on the server service | `[]` | + + +### Argo Workflows Controller configuration parameters + +| Name | Description | Value | +| -------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------- | ---------------------------------- | +| `controller.image.registry` | controller image registry | `docker.io` | +| `controller.image.repository` | controller image repository | `bitnami/argo-workflow-controller` | +| `controller.image.tag` | controller image tag (immutable tags are recommended) | `3.1.13-scratch-r0` | +| `controller.image.pullPolicy` | controller image pull policy | `IfNotPresent` | +| `controller.image.pullSecrets` | controller image pull secrets | `[]` | +| `controller.replicaCount` | Number of controller replicas to deploy | `1` | +| `controller.livenessProbe.enabled` | Enable livenessProbe on controller nodes | `true` | +| `controller.livenessProbe.initialDelaySeconds` | Initial delay seconds for livenessProbe | `90` | +| `controller.livenessProbe.periodSeconds` | Period seconds for livenessProbe | `60` | +| `controller.livenessProbe.timeoutSeconds` | Timeout seconds for livenessProbe | `30` | +| `controller.livenessProbe.failureThreshold` | Failure threshold for livenessProbe | `3` | +| `controller.livenessProbe.successThreshold` | Success threshold for livenessProbe | `1` | +| `controller.readinessProbe.enabled` | Enable readinessProbe on controller nodes | `true` | +| `controller.readinessProbe.initialDelaySeconds` | Initial delay seconds for readinessProbe | `30` | +| `controller.readinessProbe.periodSeconds` | Period seconds for readinessProbe | `60` | +| `controller.readinessProbe.timeoutSeconds` | Timeout seconds for readinessProbe | `30` | +| `controller.readinessProbe.failureThreshold` | Failure threshold for readinessProbe | `3` | +| `controller.readinessProbe.successThreshold` | Success threshold for readinessProbe | `1` | +| `controller.startupProbe.enabled` | Enable startupProbe | `false` | +| `controller.startupProbe.path` | Path to check for startupProbe | `/` | +| `controller.startupProbe.initialDelaySeconds` | Initial delay seconds for startupProbe | `300` | +| `controller.startupProbe.periodSeconds` | Period seconds for startupProbe | `10` | +| `controller.startupProbe.timeoutSeconds` | Timeout seconds for startupProbe | `5` | +| `controller.startupProbe.failureThreshold` | Failure threshold for startupProbe | `6` | +| `controller.startupProbe.successThreshold` | Success threshold for startupProbe | `1` | +| `controller.customLivenessProbe` | Controller custom livenessProbe that overrides the default one | `{}` | +| `controller.customReadinessProbe` | Controller custom readinessProbe that overrides the default one | `{}` | +| `controller.customStartupProbe` | Controller custom startupProbe that overrides the default one | `{}` | +| `controller.resources.limits` | The resources limits for the controller containers | `{}` | +| `controller.resources.requests` | The requested resources for the controller containers | `{}` | +| `controller.podSecurityContext.enabled` | Enabled controller pods' Security Context | `true` | +| `controller.podSecurityContext.fsGroup` | Set controller pod's Security Context fsGroup | `1001` | +| `controller.containerSecurityContext.enabled` | Enabled controller containers' Security Context | `true` | +| `controller.containerSecurityContext.runAsUser` | Set controller containers' Security Context runAsUser | `1001` | +| `controller.containerSecurityContext.runAsNonRoot` | Set controller containers' Security Context runAsNonRoot | `true` | +| `controller.containerPorts.metrics` | Port to expose controller metrics | `9090` | +| `controller.containerPorts.telemetry` | Port to expose controller telemetry | `8081` | +| `controller.rbac.create` | Create RBAC resources for the Argo workflows controller | `true` | +| `controller.existingConfigMap` | | `""` | +| `controller.extraArgs` | Extra arguments for the controller command line | `""` | +| `controller.config` | Controller configmap configuration content | `{}` | +| `controller.instanceID.enabled` | Enable submission filtering based on instanceID attribute. Requires to set instanceID.useReleaseName or instanceID.explicitID | `false` | +| `controller.instanceID.useReleaseName` | Use the release name to filter submissions | `false` | +| `controller.instanceID.explicitID` | Filter submissions based on an explicit instance ID | `""` | +| `controller.containerRuntimeExecutor` | Specifies the container runtime for the executor | `k8sapi` | +| `controller.clusterWorkflowTemplates.enabled` | Whether to create a ClusterRole and Cluster Role Binding to access ClusterWokflowTemplates resources | `true` | +| `controller.metrics.enabled` | Enable controller metrics exporter | `false` | +| `controller.metrics.path` | Path to expose controller metrics | `/metrics` | +| `controller.metrics.serviceMonitor.enabled` | Enable prometheus service monitor configuration | `false` | +| `controller.telemetry.enabled` | Enable telemetry for the controller | `false` | +| `controller.telemetry.path` | Path to expose telemetry information | `/telemetry` | +| `controller.workflowWorkers` | Number of workflow workers to deploy | `32` | +| `controller.podWorkers` | Number of pod workers to deploy | `32` | +| `controller.workflowNamespaces` | Namespaces allowed to run workflows | `["default"]` | +| `controller.logging.level` | Level for the controller logging | `info` | +| `controller.logging.globalLevel` | Global logging level for the controller | `0` | +| `controller.pdb.enabled` | Create Pod Disruption Budget for the controller component | `false` | +| `controller.pdb.minAvailable` | Sets the min number of pods availables for the Pod Disruption Budget | `1` | +| `controller.pdb.maxUnavailable` | Sets the max number of pods unavailable for the Pod Disruption Budget | `1` | +| `controller.serviceAccount.create` | Specifies whether a ServiceAccount should be created | `true` | +| `controller.serviceAccount.name` | Name for the service account | `""` | +| `controller.serviceAccount.automountServiceAccountToken` | Automount service account token for the controller service account | `true` | +| `controller.command` | Override default container command (useful when using custom images) | `[]` | +| `controller.args` | Override default container args (useful when using custom images) | `[]` | +| `controller.hostAliases` | controller pods host aliases | `[]` | +| `controller.podLabels` | Extra labels for controller pods | `{}` | +| `controller.podAnnotations` | Annotations for controller pods | `{}` | +| `controller.podAffinityPreset` | Pod affinity preset. Ignored if `controller.affinity` is set. Allowed values: `soft` or `hard` | `""` | +| `controller.podAntiAffinityPreset` | Pod anti-affinity preset. Ignored if `controller.affinity` is set. Allowed values: `soft` or `hard` | `soft` | +| `controller.nodeAffinityPreset.type` | Node affinity preset type. Ignored if `controller.affinity` is set. Allowed values: `soft` or `hard` | `""` | +| `controller.nodeAffinityPreset.key` | Node label key to match. Ignored if `controller.affinity` is set | `""` | +| `controller.nodeAffinityPreset.values` | Node label values to match. Ignored if `controller.affinity` is set | `[]` | +| `controller.affinity` | Affinity for controller pods assignment | `{}` | +| `controller.nodeSelector` | Node labels for controller pods assignment | `{}` | +| `controller.tolerations` | Tolerations for controller pods assignment | `[]` | +| `controller.updateStrategy.type` | controller statefulset strategy type | `RollingUpdate` | +| `controller.topologySpreadConstraints` | Topology spread constraints rely on node labels to identify the topology domain(s) that each Node is in | `[]` | +| `controller.schedulerName` | Alternate scheduler for the server controller | `""` | +| `controller.priorityClassName` | controller pods' priorityClassName | `""` | +| `controller.lifecycleHooks` | for the controller container(s) to automate configuration before or after startup | `{}` | +| `controller.extraEnvVars` | Array with extra environment variables to add to controller nodes | `[]` | +| `controller.extraEnvVarsCM` | Name of existing ConfigMap containing extra env vars for controller nodes | `""` | +| `controller.extraEnvVarsSecret` | Name of existing Secret containing extra env vars for controller nodes | `""` | +| `controller.extraVolumes` | Optionally specify extra list of additional volumes for the controller pod(s) | `[]` | +| `controller.extraVolumeMounts` | Optionally specify extra list of additional volumeMounts for the controller container(s) | `[]` | +| `controller.sidecars` | Add additional sidecar containers to the controller pod(s) | `{}` | +| `controller.initContainers` | Add additional init containers to the controller pod(s) | `{}` | +| `controller.service.type` | controller service type | `ClusterIP` | +| `controller.service.ports.metrics` | Metrics port for the controller | `8080` | +| `controller.service.ports.telemetry` | Telemetry port for the controller | `8081` | +| `controller.service.nodePorts.metrics` | Node port for HTTP | `""` | +| `controller.service.nodePorts.telemetry` | Node port for HTTPS | `""` | +| `controller.service.clusterIP` | controller service Cluster IP | `""` | +| `controller.service.loadBalancerIP` | controller service Load Balancer IP | `""` | +| `controller.service.loadBalancerSourceRanges` | controller service Load Balancer sources | `[]` | +| `controller.service.externalTrafficPolicy` | controller service external traffic policy | `Cluster` | +| `controller.service.annotations` | Additional custom annotations for controller service | `{}` | +| `controller.service.extraPorts` | Extra port to expose on the controller service | `[]` | + + +### Executor configuration section + +| Name | Description | Value | +| ------------------------------------------- | ------------------------------------------------------------- | ---------------------------- | +| `executor.image.registry` | executor image registry | `docker.io` | +| `executor.image.repository` | executor image repository | `bitnami/argo-workflow-exec` | +| `executor.image.tag` | executor image tag (immutable tags are recommended) | `3.1.13-debian-10-r2` | +| `executor.image.pullPolicy` | executor image pull policy | `Always` | +| `executor.image.pullSecrets` | executor image pull secrets | `[]` | +| `executor.resources.limits` | The resources limits for the init container | `{}` | +| `executor.resources.requests` | The requested resources for the init container | `{}` | +| `executor.extraEnvVars` | Array with extra environment variables to add to server nodes | `[]` | +| `executor.containerSecurityContext.enabled` | Enabled executor pods' Security Context | `true` | +| `executor.containerSecurityContext.fsGroup` | Set executor pod's Security Context fsGroup | `1001` | + + +### Traffic Exposure Parameters + +| Name | Description | Value | +| -------------------------- | ----------------------------------------------------------------------------------------------------- | ------------------------ | +| `ingress.enabled` | Enable ingress record generation for server | `false` | +| `ingress.pathType` | Ingress path type | `ImplementationSpecific` | +| `ingress.apiVersion` | Force Ingress API version (automatically detected if not set) | `""` | +| `ingress.hostname` | Default host for the ingress record | `server.local` | +| `ingress.path` | Default path for the ingress record | `/` | +| `ingress.ingressClassName` | IngressClass that will be be used to implement the Ingress (Kubernetes 1.18+) | `""` | +| `ingress.annotations` | Additional custom annotations for the ingress record | `{}` | +| `ingress.tls` | Enable TLS configuration for the host defined at `ingress.hostname` parameter | `false` | +| `ingress.certManager` | Add the corresponding annotations for cert-manager integration | `false` | +| `ingress.selfSigned` | Create a TLS secret for this ingress record using self-signed certificates generated by Helm | `false` | +| `ingress.extraHosts` | An array with additional hostname(s) to be covered with the ingress record | `[]` | +| `ingress.extraPaths` | An array with additional arbitrary paths that may need to be added to the ingress under the main host | `[]` | +| `ingress.extraTls` | TLS configuration for additional hostname(s) to be covered with this ingress record | `[]` | +| `ingress.secrets` | Custom TLS certificates as secrets | `[]` | + + +### Workflows configuration + +| Name | Description | Value | +| ------------------------------------------------------- | ----------------------------------------------------------------- | ------- | +| `workflows.serviceAccount.create` | Whether to create a service account to run workflows | `false` | +| `workflows.serviceAccount.name` | Service account name to run workflows | `""` | +| `workflows.serviceAccount.automountServiceAccountToken` | Automount service account token for the workflows service account | `true` | +| `workflows.rbac.create` | Whether to create RBAC resource to run workflows | `true` | + + +### PostgreSQL subchart + +| Name | Description | Value | +| ------------------------------- | ---------------------------------------------------------------------- | ------------------- | +| `postgresql.enabled` | Enable PostgreSQL subchart and controller persistence using PostgreSQL | `true` | +| `postgresql.service.port` | PostgreSQL port | `5432` | +| `postgresql.postgresqlUsername` | PostgreSQL username | `postgres` | +| `postgresql.postgresqlDatabase` | PortgreSQL database name | `bn_argo_workflows` | + + +### MySQL subchart + +| Name | Description | Value | +| --------------------- | ------------------------------------------------------------ | ------------------- | +| `mysql.enabled` | Enable MySQL subchart and controller persistence using MySQL | `false` | +| `mysql.service.port` | MySQL port | `3306` | +| `mysql.auth.username` | MySQL username | `mysql` | +| `mysql.auth.database` | MySQL database name | `bn_argo_workflows` | + + +### External Database configuration + +| Name | Description | Value | +| --------------------------------- | --------------------------------------------------------------------------- | ------------------- | +| `externalDatabase.enabled` | Enable using externaldatabase and the controller to use persistence with it | `false` | +| `externalDatabase.host` | External Database server host | `localhost` | +| `externalDatabase.port` | External Database server port | `3306` | +| `externalDatabase.username` | External Database username | `bn_wordpress` | +| `externalDatabase.password` | External Database user password | `""` | +| `externalDatabase.database` | External Database database name | `bitnami_wordpress` | +| `externalDatabase.existingSecret` | The name of an existing secret with database credentials | `""` | +| `externalDatabase.type` | Either postgresql or mysql | `""` | + + +See https://github.com/bitnami-labs/readme-generator-for-helm to create the table + +The above parameters map to the env variables defined in [bitnami/argo-workflow-cli](http://github.com/bitnami/bitnami-docker-argo-workflow-cli). For more information please refer to the [bitnami/argo-workflow-cli](http://github.com/bitnami/bitnami-docker-argo-workflows) image documentation. + +Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example, + +```console +helm install my-release \ + --set argo-workflowsUsername=admin \ + --set argo-workflowsPassword=password \ + --set mysql.auth.rootPassword=secretpassword \ + bitnami/argo-workflows +``` + +The above command sets the Argo Workflows administrator account username and password to `admin` and `password` respectively. Additionally, it sets the MySQL `root` user password to `secretpassword`. + +> NOTE: Once this chart is deployed, it is not possible to change the application's access credentials, such as usernames or passwords, using Helm. To change these application credentials after deployment, delete any persistent volumes (PVs) used by the chart and re-deploy it, or use the application's built-in administrative tools if available. + +Alternatively, a YAML file that specifies the values for the above parameters can be provided while installing the chart. For example, + +```console +helm install my-release -f values.yaml bitnami/argo-workflows +``` + +> **Tip**: You can use the default [values.yaml](values.yaml) + +## Configuration and installation details + +### [Rolling VS Immutable tags](https://docs.bitnami.com/containers/how-to/understand-rolling-tags-containers/) + +It is strongly recommended to use immutable tags in a production environment. This ensures your deployment does not change automatically if the same tag is updated with a different image. + +Bitnami will release a new chart updating its containers if a new version of the main container, significant changes, or critical vulnerabilities exist. + +### Database support + +You may want to have Argo Workflows controller connected to a database to store controller evidences. To achieve this, the chart can be deployed with the PostgreSQL or MySQL dependency (see next section to configure an external database instead of using the dependency). In order to configure the database, just change `postgresql.enabled=true` (default configuration) or `mysql.enabled=true`. The database will be configured automatically. Here is an example: + +```console +postgresql.enabled=true +``` + +If your installaion does not require to to store controller evidences, you can disable the controller persistence by setting `postgresql.enabled=false`, `mysql.enabled=false` and ` externalDatabase.enabled=false`. + +#### External database + +You may want to have Argo Workflows controller connected to an external database to store controller evidences. To achieve this, the chart allows you to specify credentials for an external database (using either postgresql or mysql) with the [`controller.persistence.postgresql.enabled` or `controller.persistence.mysql.enabled` parameter](#parameters). You should also set `persistence.enabled` to `true`. Here is an example: + +```console +externalDatabase.enabled=true +externalDatabase.type=postgresql +externalDatabase.host= +externalDatabase.port=5432 +externalDatabase.user= +externalDatabase.password= +externalDatabase.database=bitnami_wordpress +``` + +### Ingress + +This chart provides support for Ingress resources. If you have an ingress controller installed on your cluster, such as [nginx-ingress-controller](https://github.com/bitnami/charts/tree/master/bitnami/nginx-ingress-controller) or [contour](https://github.com/bitnami/charts/tree/master/bitnami/contour) you can utilize the ingress controller to serve your application. + +To enable Ingress integration, set `ingress.enabled` to `true`. The `ingress.hostname` property can be used to set the host name. The `ingress.tls` parameter can be used to add the TLS configuration for this host. It is also possible to have more than one host, with a separate TLS configuration for each host. [Learn more about configuring and using Ingress](https://docs.bitnami.com/kubernetes/apps/argo-workflows/configuration/configure-use-ingress/). + +### TLS secrets + +The chart also facilitates the creation of TLS secrets for use with the Ingress controller, with different options for certificate management. [Learn more about TLS secrets](https://docs.bitnami.com/kubernetes/apps/argo-workflows/administration/enable-tls/). + +### Additional environment variables + +In case you want to add extra environment variables (useful for advanced operations like custom init scripts), you can use the `extraEnvVars` property. + +```yaml +argo-workflows: + extraEnvVars: + - name: LOG_LEVEL + value: error +``` + +Alternatively, you can use a ConfigMap or a Secret with the environment variables. To do so, use the `extraEnvVarsCM` or the `extraEnvVarsSecret` values. + +### Sidecars + +If additional containers are needed in the same pod as argo-workflows (such as additional metrics or logging exporters), they can be defined using the `sidecars` parameter. If these sidecars export extra ports, extra port definitions can be added using the `service.extraPorts` parameter. [Learn more about configuring and using sidecar containers](https://docs.bitnami.com/kubernetes/apps/argo-workflows/administration/configure-use-sidecars/). + +### Pod affinity + +This chart allows you to set your custom affinity using the `affinity` parameter. Find more information about Pod affinity in the [kubernetes documentation](https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity). + +As an alternative, use one of the preset configurations for pod affinity, pod anti-affinity, and node affinity available at the [bitnami/common](https://github.com/bitnami/charts/tree/master/bitnami/common#affinities) chart. To do so, set the `podAffinityPreset`, `podAntiAffinityPreset`, or `nodeAffinityPreset` parameters. + +## Troubleshooting + +Find more information about how to deal with common errors related to Bitnami's Helm charts in [this troubleshooting guide](https://docs.bitnami.com/general/how-to/troubleshoot-helm-chart-issues). diff --git a/bitnami/argo-workflows/crds/argoproj.io_clusterworkflowtemplates.yaml b/bitnami/argo-workflows/crds/argoproj.io_clusterworkflowtemplates.yaml new file mode 100644 index 000000000..fa7da83a9 --- /dev/null +++ b/bitnami/argo-workflows/crds/argoproj.io_clusterworkflowtemplates.yaml @@ -0,0 +1,35 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + name: clusterworkflowtemplates.argoproj.io +spec: + group: argoproj.io + names: + kind: ClusterWorkflowTemplate + listKind: ClusterWorkflowTemplateList + plural: clusterworkflowtemplates + shortNames: + - clusterwftmpl + - cwft + singular: clusterworkflowtemplate + scope: Cluster + versions: + - name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + type: object + x-kubernetes-preserve-unknown-fields: true + required: + - metadata + - spec + type: object + served: true + storage: true diff --git a/bitnami/argo-workflows/crds/argoproj.io_cronworkflows.yaml b/bitnami/argo-workflows/crds/argoproj.io_cronworkflows.yaml new file mode 100644 index 000000000..2878fe9b4 --- /dev/null +++ b/bitnami/argo-workflows/crds/argoproj.io_cronworkflows.yaml @@ -0,0 +1,38 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + name: cronworkflows.argoproj.io +spec: + group: argoproj.io + names: + kind: CronWorkflow + listKind: CronWorkflowList + plural: cronworkflows + shortNames: + - cwf + - cronwf + singular: cronworkflow + scope: Namespaced + versions: + - name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + type: object + x-kubernetes-preserve-unknown-fields: true + status: + type: object + x-kubernetes-preserve-unknown-fields: true + required: + - metadata + - spec + type: object + served: true + storage: true diff --git a/bitnami/argo-workflows/crds/argoproj.io_eventbus.yaml b/bitnami/argo-workflows/crds/argoproj.io_eventbus.yaml new file mode 100644 index 000000000..052984c64 --- /dev/null +++ b/bitnami/argo-workflows/crds/argoproj.io_eventbus.yaml @@ -0,0 +1,40 @@ +--- +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + name: eventbus.argoproj.io +spec: + group: argoproj.io + names: + kind: EventBus + listKind: EventBusList + plural: eventbus + shortNames: + - eb + singular: eventbus + scope: Namespaced + versions: + - name: v1alpha1 + served: true + storage: true + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + type: object + x-kubernetes-preserve-unknown-fields: true + status: + type: object + x-kubernetes-preserve-unknown-fields: true + required: + - metadata + - spec + type: object + subresources: + status: {} diff --git a/bitnami/argo-workflows/crds/argoproj.io_eventsources.yaml b/bitnami/argo-workflows/crds/argoproj.io_eventsources.yaml new file mode 100644 index 000000000..ea49a4aae --- /dev/null +++ b/bitnami/argo-workflows/crds/argoproj.io_eventsources.yaml @@ -0,0 +1,40 @@ +--- +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + name: eventsources.argoproj.io +spec: + group: argoproj.io + scope: Namespaced + names: + kind: EventSource + plural: eventsources + singular: eventsource + listKind: EventSourceList + shortNames: + - es + versions: + - name: v1alpha1 + served: true + storage: true + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + type: object + x-kubernetes-preserve-unknown-fields: true + status: + type: object + x-kubernetes-preserve-unknown-fields: true + required: + - metadata + - spec + type: object + subresources: + status: {} diff --git a/bitnami/argo-workflows/crds/argoproj.io_sensors.yaml b/bitnami/argo-workflows/crds/argoproj.io_sensors.yaml new file mode 100644 index 000000000..d2414bc32 --- /dev/null +++ b/bitnami/argo-workflows/crds/argoproj.io_sensors.yaml @@ -0,0 +1,40 @@ +--- +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + name: sensors.argoproj.io +spec: + group: argoproj.io + names: + kind: Sensor + listKind: SensorList + plural: sensors + singular: sensor + shortNames: + - sn + scope: Namespaced + versions: + - name: v1alpha1 + served: true + storage: true + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + type: object + x-kubernetes-preserve-unknown-fields: true + status: + type: object + x-kubernetes-preserve-unknown-fields: true + required: + - metadata + - spec + type: object + subresources: + status: {} diff --git a/bitnami/argo-workflows/crds/argoproj.io_workfloweventbindings.yaml b/bitnami/argo-workflows/crds/argoproj.io_workfloweventbindings.yaml new file mode 100644 index 000000000..9585686a3 --- /dev/null +++ b/bitnami/argo-workflows/crds/argoproj.io_workfloweventbindings.yaml @@ -0,0 +1,34 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + name: workfloweventbindings.argoproj.io +spec: + group: argoproj.io + names: + kind: WorkflowEventBinding + listKind: WorkflowEventBindingList + plural: workfloweventbindings + shortNames: + - wfeb + singular: workfloweventbinding + scope: Namespaced + versions: + - name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + type: object + x-kubernetes-preserve-unknown-fields: true + required: + - metadata + - spec + type: object + served: true + storage: true diff --git a/bitnami/argo-workflows/crds/argoproj.io_workflows.yaml b/bitnami/argo-workflows/crds/argoproj.io_workflows.yaml new file mode 100644 index 000000000..59d2fc3bc --- /dev/null +++ b/bitnami/argo-workflows/crds/argoproj.io_workflows.yaml @@ -0,0 +1,50 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + name: workflows.argoproj.io +spec: + group: argoproj.io + names: + kind: Workflow + listKind: WorkflowList + plural: workflows + shortNames: + - wf + singular: workflow + scope: Namespaced + versions: + - additionalPrinterColumns: + - description: Status of the workflow + jsonPath: .status.phase + name: Status + type: string + - description: When the workflow was started + format: date-time + jsonPath: .status.startedAt + name: Age + type: date + name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + type: object + x-kubernetes-preserve-unknown-fields: true + x-kubernetes-map-type: atomic + status: + type: object + x-kubernetes-preserve-unknown-fields: true + x-kubernetes-map-type: atomic + required: + - metadata + - spec + type: object + served: true + storage: true + subresources: {} diff --git a/bitnami/argo-workflows/crds/argoproj.io_workflowtasksets.yaml b/bitnami/argo-workflows/crds/argoproj.io_workflowtasksets.yaml new file mode 100644 index 000000000..2d3c2dfa3 --- /dev/null +++ b/bitnami/argo-workflows/crds/argoproj.io_workflowtasksets.yaml @@ -0,0 +1,39 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + name: workflowtasksets.argoproj.io +spec: + group: argoproj.io + names: + kind: WorkflowTaskSet + listKind: WorkflowTaskSetList + plural: workflowtasksets + shortNames: + - wfts + singular: workflowtaskset + scope: Namespaced + versions: + - name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + type: object + x-kubernetes-map-type: atomic + x-kubernetes-preserve-unknown-fields: true + status: + type: object + x-kubernetes-map-type: atomic + x-kubernetes-preserve-unknown-fields: true + required: + - metadata + - spec + type: object + served: true + storage: true diff --git a/bitnami/argo-workflows/crds/argoproj.io_workflowtemplates.yaml b/bitnami/argo-workflows/crds/argoproj.io_workflowtemplates.yaml new file mode 100644 index 000000000..f6fa080ae --- /dev/null +++ b/bitnami/argo-workflows/crds/argoproj.io_workflowtemplates.yaml @@ -0,0 +1,34 @@ +apiVersion: apiextensions.k8s.io/v1 +kind: CustomResourceDefinition +metadata: + name: workflowtemplates.argoproj.io +spec: + group: argoproj.io + names: + kind: WorkflowTemplate + listKind: WorkflowTemplateList + plural: workflowtemplates + shortNames: + - wftmpl + singular: workflowtemplate + scope: Namespaced + versions: + - name: v1alpha1 + schema: + openAPIV3Schema: + properties: + apiVersion: + type: string + kind: + type: string + metadata: + type: object + spec: + type: object + x-kubernetes-preserve-unknown-fields: true + required: + - metadata + - spec + type: object + served: true + storage: true diff --git a/bitnami/argo-workflows/templates/NOTES.txt b/bitnami/argo-workflows/templates/NOTES.txt new file mode 100644 index 000000000..da41e033b --- /dev/null +++ b/bitnami/argo-workflows/templates/NOTES.txt @@ -0,0 +1,48 @@ +** Please be patient while the chart is being deployed ** + +Obtain the Argo Workflows UI URL: + +{{- if .Values.ingress.enabled }} + + export CLUSTER_IP=$(minikube ip) # On Minikube. Use: `kubectl cluster-info` on others K8s clusters + echo "Argo Workflows UI URL: http{{ if .Values.ingress.tls }}s{{ end }}://{{ .Values.ingress.hostname }}/" + echo "$CLUSTER_IP {{ .Values.ingress.hostname }}" | sudo tee -a /etc/hosts + +{{- else }} + +{{- if contains "ClusterIP" .Values.server.service.type }} + + kubectl port-forward --namespace {{ .Release.Namespace }} svc/{{ include "argo-workflows.server.fullname" . }} 8080:{{ .Values.server.service.ports.http }} & + echo "Argo Workflows UI URL: http://127.0.0.1:8080/" + +{{- else if contains "NodePort" .Values.server.service.type }} + + export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ include "argo-workflows.server.fullname" . }}) + export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}") + echo "Argo Workflows UI URL: http://$NODE_IP:$NODE_PORT/" + +{{- else if contains "LoadBalancer" .Values.server.service.type }} + + NOTE: It may take a few minutes for the LoadBalancer IP to be available. + Watch the status with: 'kubectl get svc --namespace {{ .Release.Namespace }} -w {{ include "argo-workflows.server.fullname" . }}' + + export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include "argo-workflows.server.fullname" . }} --template "{{"{{ range (index .status.loadBalancer.ingress 0) }}{{.}}{{ end }}"}}") + echo "Argo Workflows UI URL: http://$SERVICE_IP:{{ .Values.server.service.ports.http }}/" + +{{- end }} +{{- end }} + +{{- if and .Values.server.auth.enabled (contains .Values.server.auth.mode "client") }} + +Obtain the Argo Workflows access token: + + SECRET=$(kubectl get sa {{ include "argo-workflows.server.serviceAccountName" . }} -o=jsonpath='{.secrets[0].name}') + ARGO_TOKEN="Bearer $(kubectl get secret $SECRET -o=jsonpath='{.data.token}' | base64 --decode)" + echo "$ARGO_TOKEN" + +{{- end }} + +{{- include "common.warnings.rollingTag" .Values.server.image }} +{{- include "common.warnings.rollingTag" .Values.controller.image }} +{{- include "common.warnings.rollingTag" .Values.executor.image }} +{{- include "argo-workflows.validateValues" . }} diff --git a/bitnami/argo-workflows/templates/_helpers.tpl b/bitnami/argo-workflows/templates/_helpers.tpl new file mode 100644 index 000000000..2ada81058 --- /dev/null +++ b/bitnami/argo-workflows/templates/_helpers.tpl @@ -0,0 +1,243 @@ +{{/* +Return the proper server image name +*/}} +{{- define "argo-workflows.server.image" -}} +{{ include "common.images.image" (dict "imageRoot" .Values.server.image "global" .Values.global) }} +{{- end -}} + +{{/* +Return the proper controller image name +*/}} +{{- define "argo-workflows.controller.image" -}} +{{ include "common.images.image" (dict "imageRoot" .Values.controller.image "global" .Values.global) }} +{{- end -}} + +{{/* +Return the proper executor image name +*/}} +{{- define "argo-workflows.executor.image" -}} +{{ include "common.images.image" (dict "imageRoot" .Values.executor.image "global" .Values.global) }} +{{- end -}} + +{{/* +Return the proper service name for Argo Workflows server +*/}} +{{- define "argo-workflows.server.fullname" -}} + {{- printf "%s-server" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }} +{{- end -}} + +{{/* +Return the proper service name for Argo Workflows controller +*/}} +{{- define "argo-workflows.controller.fullname" -}} + {{- printf "%s-controller" (include "common.names.fullname" .) | trunc 63 | trimSuffix "-" }} +{{- end -}} + +{{/* +Create a default fully qualified postgresql name. +We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). +*/}} +{{- define "argo-workflows.postgresql.fullname" -}} +{{- $name := default "postgresql" .Values.postgresql.nameOverride -}} +{{- include "common.names.dependency.fullname" (dict "chartName" "postgresql" "chartValues" .Values.postgresql "context" $) -}} +{{- end -}} + +{{/* +Create a default fully qualified mysql name. +We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). +*/}} +{{- define "argo-workflows.mysql.fullname" -}} +{{- $name := default "mysql" .Values.mysql.nameOverride -}} +{{- include "common.names.dependency.fullname" (dict "chartName" "mysql" "chartValues" .Values.mysql "context" $) -}} +{{- end -}} + +{{/* +Create the name of the server service account to use +*/}} +{{- define "argo-workflows.server.serviceAccountName" -}} +{{- if .Values.server.serviceAccount.create -}} + {{ default (printf "%s-server" (include "common.names.fullname" .)) .Values.server.serviceAccount.name }} +{{- else -}} + {{ default "default" .Values.server.serviceAccount.name }} +{{- end -}} +{{- end -}} + +{{/* +Create the name of the controller service account to use +*/}} +{{- define "argo-workflows.controller.serviceAccountName" -}} +{{- if .Values.controller.serviceAccount.create -}} + {{ default (printf "%s-controller" (include "common.names.fullname" .)) .Values.controller.serviceAccount.name }} +{{- else -}} + {{ default "default" .Values.controller.serviceAccount.name }} +{{- end -}} +{{- end -}} + +{{/* +Create the name of the workflows service account to use +*/}} +{{- define "argo-workflows.workflows.serviceAccountName" -}} +{{- if .Values.workflows.serviceAccount.create -}} + {{ default (printf "%s-workflows" (include "common.names.fullname" .)) .Values.workflows.serviceAccount.name }} +{{- else -}} + {{ default "default" .Values.workflows.serviceAccount.name }} +{{- end -}} +{{- end -}} + +{{/* +Return the proper Docker Image Registry Secret Names +*/}} +{{- define "argo-workflows.imagePullSecrets" -}} +{{- include "common.images.pullSecrets" (dict "images" (list .Values.server.image .Values.controller.image) "global" .Values.global) -}} +{{- end -}} + +{{/* +Return the proper configmap for the controller +*/}} +{{- define "argo-workflows.controller.configMapName" -}} +{{- if .Values.controller.existingConfigMap }} +{{- .Values.controller.existingConfigMap -}} +{{- else -}} +{{- include "argo-workflows.controller.fullname" . -}} +{{- end -}} +{{- end -}} + +{{/* +Return true if persistence is enabled +*/}} +{{- define "argo-workflows.controller.persistence.enabled" -}} +{{- if or .Values.postgresql.enabled .Values.mysql.enabled .Values.externalDatabase.enabled -}} +{{- true -}} +{{- end -}} +{{- end -}} + +{{/* +Return the proper database username +*/}} +{{- define "argo-workflows.controller.database.username" -}} +{{- if .Values.postgresql.enabled -}} +{{- .Values.postgresql.postgresqlUsername -}} +{{- end -}} +{{- if .Values.mysql.enabled -}} +{{- .Values.mysql.auth.username -}} +{{- end -}} +{{- if .Values.externalDatabase.enabled -}} +{{- .Values.externalDatabase.username -}} +{{- end -}} +{{- end -}} + +{{/* +Return the proper database username secret name +*/}} +{{- define "argo-workflows.controller.database.username.secret" -}} +{{- printf "%s-%s" (include "argo-workflows.controller.fullname" .) "database" -}} +{{- end -}} + +{{/* +Return the proper database password secret +*/}} +{{- define "argo-workflows.controller.database.password.secret" -}} +{{- if .Values.postgresql.enabled -}} +{{- include "argo-workflows.postgresql.fullname" . -}} +{{- end -}} +{{- if .Values.mysql.enabled -}} +{{- include "argo-workflows.mysql.fullname" . -}} +{{- end -}} +{{- if .Values.externalDatabase.enabled -}} +{{- if .Values.externalDatabase.existingSecret -}} +{{- tpl .Values.externalDatabase.existingSecret . -}} +{{- else -}} +{{- include "argo-workflows.controller.database.username.secret" . -}} +{{- end -}} +{{- end -}} +{{- end -}} + +{{/* +Return the proper database password secret key +*/}} +{{- define "argo-workflows.controller.database.password.secret.key" -}} +{{- if .Values.postgresql.enabled -}} +{{- printf "%s" "postgresql-password" -}} +{{- end -}} +{{- if .Values.mysql.enabled -}} +{{- printf "%s" "mysql-password" -}} +{{- end -}} +{{- if .Values.externalDatabase.enabled -}} +{{- printf "%s" "database-password" -}} +{{- end -}} +{{- end -}} + +{{/* +Return the proper database host +The validate values function checks that both types are not set at the same time +*/}} +{{- define "argo-workflows.controller.database.host" -}} +{{- if .Values.postgresql.enabled -}} +{{- include "argo-workflows.postgresql.fullname" . -}} +{{- end -}} +{{- if .Values.mysql.enabled -}} +{{- include "argo-workflows.mysql.fullname" . -}} +{{- end -}} +{{- if .Values.externalDatabase.enabled -}} +{{- .Values.externalDatabase.host -}} +{{- end -}} +{{- end -}} + +{{/* +Return the proper database +*/}} +{{- define "argo-workflows.controller.database" -}} +{{- if .Values.postgresql.enabled -}} +{{- .Values.postgresql.postgresqlDatabase -}} +{{- end -}} +{{- if .Values.mysql.enabled -}} +{{- .Values.mysql.auth.database -}} +{{- end -}} +{{- if .Values.externalDatabase.enabled -}} +{{- .Values.externalDatabase.database -}} +{{- end -}} +{{- end -}} + +{{/* +Return the proper database port +*/}} +{{- define "argo-workflows.controller.database.port" -}} +{{- if .Values.postgresql.enabled -}} +{{- .Values.postgresql.service.port -}} +{{- end -}} +{{- if .Values.mysql.enabled -}} +{{- .Values.mysql.service.port -}} +{{- end -}} +{{- if .Values.externalDatabase.enabled -}} +{{- .Values.externalDatabase.port -}} +{{- end -}} +{{- end -}} + +{{/* +Validate database configuration +*/}} +{{- define "argo-workflows.validate.database.config" -}} +{{- if or (and .Values.postgresql.enabled .Values.mysql.enabled) (and .Values.externalDatabase.enabled .Values.mysql.enabled) (and .Values.postgresql.enabled .Values.externalDatabase.enabled) -}} +{{- printf "Validation error: more than one type of database specified, you should either configure postgresql, mysql or an external database" -}} +{{- end -}} +{{- if and .Values.externalDatabase.enabled (not .Values.externalDatabase.database) -}} +{{- printf "Validation error: External database provided without the database parameter" -}} +{{- end -}} +{{- if and .Values.externalDatabase.enabled (not .Values.externalDatabase.type) -}} +{{- printf "Validation error: External database provided without the database type parameter" -}} +{{- end -}} +{{- end -}} + +{{/* +Compile all warnings into a single message. +*/}} +{{- define "argo-workflows.validateValues" -}} +{{- $messages := list -}} +{{- $messages := append $messages (include "argo-workflows.validate.database.config" .) -}} +{{- $messages := without $messages "" -}} +{{- $message := join "\n" $messages -}} + +{{- if $message -}} +{{- printf "\nVALUES VALIDATION:\n%s" $message -}} +{{- end -}} +{{- end -}} diff --git a/bitnami/argo-workflows/templates/configmap.yaml b/bitnami/argo-workflows/templates/configmap.yaml new file mode 100644 index 000000000..fbae81ac3 --- /dev/null +++ b/bitnami/argo-workflows/templates/configmap.yaml @@ -0,0 +1,19 @@ +{{- if not .Values.controller.existingConfigMap }} +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ include "argo-workflows.controller.fullname" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: controller + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +data: + config: | + {{- include "common.tplvalues.render" ( dict "value" .Values.controller.config "context" $ ) | nindent 4 }} +{{- end }} diff --git a/bitnami/argo-workflows/templates/controller/aggregate-cluster-roles.yaml b/bitnami/argo-workflows/templates/controller/aggregate-cluster-roles.yaml new file mode 100644 index 000000000..4da7374ab --- /dev/null +++ b/bitnami/argo-workflows/templates/controller/aggregate-cluster-roles.yaml @@ -0,0 +1,119 @@ +{{- if and .Values.createAggregateRoles .Values.controller.rbac.create }} +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + name: {{ include "common.names.fullname" . }}-view + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + rbac.authorization.k8s.io/aggregate-to-view: "true" + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: controller + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +rules: + - apiGroups: + - argoproj.io + resources: + - workflows + - workflows/finalizers + - workflowtasksets + - workflowtasksets/finalizers + - workfloweventbindings + - workfloweventbindings/finalizers + - workflowtemplates + - workflowtemplates/finalizers + - cronworkflows + - cronworkflows/finalizers + - clusterworkflowtemplates + - clusterworkflowtemplates/finalizers + verbs: + - get + - list + - watch +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + name: {{ include "common.names.fullname" . }}-edit + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + rbac.authorization.k8s.io/aggregate-to-edit: "true" + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: controller + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +rules: + - apiGroups: + - argoproj.io + resources: + - workflows + - workflows/finalizers + - workflowtasksets + - workflowtasksets/finalizers + - workfloweventbindings + - workfloweventbindings/finalizers + - workflowtemplates + - workflowtemplates/finalizers + - cronworkflows + - cronworkflows/finalizers + - clusterworkflowtemplates + - clusterworkflowtemplates/finalizers + verbs: + - create + - delete + - deletecollection + - get + - list + - patch + - update + - watch +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + name: {{ include "common.names.fullname" . }}-admin + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + rbac.authorization.k8s.io/aggregate-to-admin: "true" + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: controller + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +rules: + - apiGroups: + - argoproj.io + resources: + - workflows + - workflows/finalizers + - workflowtasksets + - workflowtasksets/finalizers + - workfloweventbindings + - workfloweventbindings/finalizers + - workflowtemplates + - workflowtemplates/finalizers + - cronworkflows + - cronworkflows/finalizers + - clusterworkflowtemplates + - clusterworkflowtemplates/finalizers + verbs: + - create + - delete + - deletecollection + - get + - list + - patch + - update + - watch +{{- end }} diff --git a/bitnami/argo-workflows/templates/controller/clusterrolebinding.yaml b/bitnami/argo-workflows/templates/controller/clusterrolebinding.yaml new file mode 100644 index 000000000..b8b33c3e2 --- /dev/null +++ b/bitnami/argo-workflows/templates/controller/clusterrolebinding.yaml @@ -0,0 +1,68 @@ +{{- if .Values.controller.rbac.create }} +apiVersion: rbac.authorization.k8s.io/v1 +{{- if .Values.rbac.singleNamespace }} +kind: RoleBinding +{{ else }} +kind: ClusterRoleBinding +{{- end }} +metadata: + name: {{ include "argo-workflows.controller.fullname" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: controller + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +roleRef: + apiGroup: rbac.authorization.k8s.io + {{- if .Values.rbac.singleNamespace }} + kind: Role + {{ else }} + kind: ClusterRole + {{- end }} + name: {{ include "argo-workflows.controller.fullname" . }} +subjects: + - kind: ServiceAccount + name: {{ include "argo-workflows.controller.serviceAccountName" . }} + namespace: {{ .Release.Namespace }} +{{- if .Values.controller.workflowNamespaces }} +{{- $uiServiceAccount := (include "argo-workflows.controller.serviceAccountName" .) }} +{{- $namespace := .Release.Namespace }} +{{- range $key := .Values.controller.workflowNamespaces }} + {{- if not (eq $key $namespace) }} + - kind: ServiceAccount + name: {{ $uiServiceAccount }} + namespace: {{ $key }} + {{- end }} +{{- end }} +{{- end }} + +{{- if .Values.controller.clusterWorkflowTemplates.enabled }} +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRoleBinding +metadata: + name: {{ include "argo-workflows.controller.fullname" . }}-cluster-template + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/component: controller + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: ClusterRole + name: {{ include "argo-workflows.controller.fullname" . }}-cluster-template +subjects: + - kind: ServiceAccount + name: {{ include "argo-workflows.controller.serviceAccountName" . }} + namespace: {{ .Release.Namespace }} +{{- end }} +{{- end }} \ No newline at end of file diff --git a/bitnami/argo-workflows/templates/controller/controller-cluster-roles.yaml b/bitnami/argo-workflows/templates/controller/controller-cluster-roles.yaml new file mode 100644 index 000000000..1dd213064 --- /dev/null +++ b/bitnami/argo-workflows/templates/controller/controller-cluster-roles.yaml @@ -0,0 +1,175 @@ +{{- if .Values.controller.rbac.create }} +apiVersion: rbac.authorization.k8s.io/v1 +{{- if .Values.rbac.singleNamespace }} +kind: Role +{{- else }} +kind: ClusterRole +{{- end }} +metadata: + name: {{ include "argo-workflows.controller.fullname" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: controller + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +rules: + - apiGroups: + - "" + resources: + - pods + - pods/exec + verbs: + - create + - get + - list + - watch + - update + - patch + - delete + - apiGroups: + - "" + resources: + - configmaps + verbs: + - get + - watch + - list + - apiGroups: + - "" + resources: + - persistentvolumeclaims + verbs: + - create + - delete + - apiGroups: + - argoproj.io + resources: + - workflows + - workflows/finalizers + - workflowtasksets + - workflowtasksets/finalizers + verbs: + - get + - list + - watch + - update + - patch + - delete + - create + - apiGroups: + - argoproj.io + resources: + - workflowtemplates + - workflowtemplates/finalizers + verbs: + - get + - list + - watch + - apiGroups: + - argoproj.io + resources: + - cronworkflows + - cronworkflows/finalizers + verbs: + - get + - list + - watch + - update + - patch + - delete + - apiGroups: + - "" + resources: + - events + verbs: + - create + - patch + - apiGroups: + - "" + resources: + - serviceaccounts + verbs: + - get + - list + - apiGroups: + - "policy" + resources: + - poddisruptionbudgets + verbs: + - create + - get + - delete + {{- if (include "argo-workflows.controller.persistence.enabled" .) }} + - apiGroups: + - "" + resources: + - secrets + resourceNames: + - {{ include "argo-workflows.controller.database.username.secret" . }} + - {{ include "argo-workflows.controller.database.password.secret" . }} + verbs: + - get + {{- end }} + - apiGroups: + - coordination.k8s.io + resources: + - leases + verbs: + - create + - apiGroups: + - coordination.k8s.io + resources: + - leases + resourceNames: + {{- if .Values.controller.instanceID.enabled }} + {{- if .Values.controller.instanceID.useReleaseName }} + - workflow-controller-{{ .Release.Name }} + - workflow-controller-lease-{{ .Release.Name }} + {{- else }} + - workflow-controller-{{ .Values.controller.instanceID.explicitID }} + - workflow-controller-lease-{{ .Values.controller.instanceID.explicitID }} + {{- end }} + {{- else }} + - workflow-controller + - workflow-controller-lease + {{- end }} + verbs: + - get + - watch + - update + - patch + - delete + +{{- if .Values.controller.clusterWorkflowTemplates.enabled }} +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + name: {{ include "argo-workflows.controller.fullname" . }}-cluster-template + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: controller + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +rules: + - apiGroups: + - argoproj.io + resources: + - clusterworkflowtemplates + - clusterworkflowtemplates/finalizers + verbs: + - get + - list + - watch +{{- end }} +{{- end }} \ No newline at end of file diff --git a/bitnami/argo-workflows/templates/controller/database-secret.yaml b/bitnami/argo-workflows/templates/controller/database-secret.yaml new file mode 100644 index 000000000..98a34d4ef --- /dev/null +++ b/bitnami/argo-workflows/templates/controller/database-secret.yaml @@ -0,0 +1,22 @@ +{{- if (include "argo-workflows.controller.persistence.enabled" .) }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ include "argo-workflows.controller.database.username.secret" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/component: controller + app.kubernetes.io/part-of: argo-workflows + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +type: Opaque +data: + username: {{ include "argo-workflows.controller.database.username" . | b64enc }} + {{- if and .Values.externalDatabase.enabled (not .Values.externalDatabase.existingSecret)}} + database-password: {{ .Values.externalDatabase.password | b64enc }} + {{- end }} +{{- end }} \ No newline at end of file diff --git a/bitnami/argo-workflows/templates/controller/deployment.yaml b/bitnami/argo-workflows/templates/controller/deployment.yaml new file mode 100644 index 000000000..824b029ca --- /dev/null +++ b/bitnami/argo-workflows/templates/controller/deployment.yaml @@ -0,0 +1,199 @@ +apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} +kind: Deployment +metadata: + name: {{ include "argo-workflows.controller.fullname" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/component: controller + app.kubernetes.io/part-of: argo-workflows + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + replicas: {{ .Values.controller.replicaCount }} + {{- if .Values.controller.updateStrategy }} + strategy: {{- toYaml .Values.controller.updateStrategy | nindent 4 }} + {{- end }} + selector: + matchLabels: {{- include "common.labels.matchLabels" . | nindent 6 }} + app.kubernetes.io/component: controller + template: + metadata: + annotations: + checksum/config: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }} + {{- if .Values.controller.podAnnotations }} + {{- include "common.tplvalues.render" (dict "value" .Values.controller.podAnnotations "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.commonAnnotations }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} + labels: {{- include "common.labels.standard" . | nindent 8 }} + app.kubernetes.io/component: controller + {{- if .Values.controller.podLabels }} + {{- include "common.tplvalues.render" (dict "value" .Values.controller.podLabels "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + spec: + {{- if .Values.controller.schedulerName }} + schedulerName: {{ .Values.controller.schedulerName | quote }} + {{- end }} + serviceAccountName: {{ include "argo-workflows.controller.serviceAccountName" . }} + {{- include "argo-workflows.imagePullSecrets" . | nindent 6 }} + {{- if .Values.controller.hostAliases }} + hostAliases: {{- include "common.tplvalues.render" (dict "value" .Values.controller.hostAliases "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.controller.affinity }} + affinity: {{- include "common.tplvalues.render" ( dict "value" .Values.controller.affinity "context" $) | nindent 8 }} + {{- else }} + affinity: + podAffinity: {{- include "common.affinities.pods" (dict "type" .Values.controller.podAffinityPreset "component" "controller" "context" $) | nindent 10 }} + podAntiAffinity: {{- include "common.affinities.pods" (dict "type" .Values.controller.podAntiAffinityPreset "component" "controller" "context" $) | nindent 10 }} + nodeAffinity: {{- include "common.affinities.nodes" (dict "type" .Values.controller.nodeAffinityPreset.type "key" .Values.controller.nodeAffinityPreset.key "values" .Values.controller.nodeAffinityPreset.values) | nindent 10 }} + {{- end }} + {{- if .Values.controller.nodeSelector }} + nodeSelector: {{- include "common.tplvalues.render" ( dict "value" .Values.controller.nodeSelector "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.controller.tolerations }} + tolerations: {{- include "common.tplvalues.render" (dict "value" .Values.controller.tolerations "context" .) | nindent 8 }} + {{- end }} + {{- if .Values.controller.topologySpreadConstraints }} + topologySpreadConstraints: {{- include "common.tplvalues.render" (dict "value" .Values.controller.topologySpreadConstraints "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.controller.priorityClassName }} + priorityClassName: {{ .Values.controller.priorityClassName | quote }} + {{- end }} + {{- if .Values.controller.podSecurityContext.enabled }} + securityContext: {{- omit .Values.controller.podSecurityContext "enabled" | toYaml | nindent 8 }} + {{- end }} + {{- if .Values.controller.initContainers }} + initContainers: + {{- include "common.tplvalues.render" (dict "value" .Values.controller.initContainers "context" $) | nindent 8 }} + {{- end }} + containers: + - name: controller + image: {{ include "argo-workflows.controller.image" . }} + imagePullPolicy: {{ .Values.controller.image.pullPolicy }} + {{- if .Values.controller.containerSecurityContext.enabled }} + securityContext: {{- omit .Values.controller.containerSecurityContext "enabled" | toYaml | nindent 12 }} + {{- end }} + {{- if .Values.controller.command }} + command: {{- include "common.tplvalues.render" (dict "value" .Values.controller.command "context" $) | nindent 12 }} + {{- end }} + args: + {{- if .Values.controller.args }} + {{- include "common.tplvalues.render" (dict "value" .Values.controller.args "context" $) | nindent 12 }} + {{- else }} + - --configmap + - {{ include "argo-workflows.controller.configMapName" . }} + - --executor-image + - {{ include "argo-workflows.executor.image" . }} + - --executor-image-pull-policy + - {{ .Values.executor.image.pullPolicy }} + - --loglevel + - {{ .Values.controller.logging.level }} + - --gloglevel + - {{ .Values.controller.logging.globalLevel | quote }} + {{- if .Values.rbac.singleNamespace }} + - --namespaced + {{- end }} + {{- if .Values.controller.workflowWorkers }} + - --workflow-workers + - {{ .Values.controller.workflowWorkers | quote }} + {{- end }} + {{- if .Values.controller.podWorkers }} + - --pod-workers + - {{ .Values.controller.podWorkers | quote }} + {{- end }} + {{- if .Values.controller.extraArgs }} + {{- include "common.tplvalues.render" (dict "value" .Values.controller.extraArgs "context" $) | nindent 12 }} + {{- end }} + {{- end }} + env: + - name: ARGO_NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + - name: LEADER_ELECTION_IDENTITY + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.name + {{- if .Values.controller.extraEnvVars }} + {{- include "common.tplvalues.render" (dict "value" .Values.controller.extraEnvVars "context" $) | nindent 12 }} + {{- end }} + envFrom: + {{- if .Values.controller.extraEnvVarsCM }} + - configMapRef: + name: {{ include "common.tplvalues.render" (dict "value" .Values.controller.extraEnvVarsCM "context" $) }} + {{- end }} + {{- if .Values.controller.extraEnvVarsSecret }} + - secretRef: + name: {{ include "common.tplvalues.render" (dict "value" .Values.controller.extraEnvVarsSecret "context" $) }} + {{- end }} + ports: + - name: metrics + containerPort: {{ .Values.controller.containerPorts.metrics }} + - name: controller + # The controller port is hardcoded in the source code. + # Ref: https://github.com/argoproj/argo-workflows/blob/b35aabe86be9fa5db80299cebcfb29c32be21047/cmd/workflow-controller/main.go#L116 + containerPort: 6060 + {{- if .Values.controller.resources }} + resources: {{- toYaml .Values.controller.resources | nindent 12 }} + {{- end }} + {{- if .Values.controller.livenessProbe.enabled }} + livenessProbe: + tcpSocket: + port: 6060 + initialDelaySeconds: {{ .Values.controller.livenessProbe.initialDelaySeconds }} + periodSeconds: {{ .Values.controller.livenessProbe.periodSeconds }} + timeoutSeconds: {{ .Values.controller.livenessProbe.timeoutSeconds }} + successThreshold: {{ .Values.controller.livenessProbe.successThreshold }} + failureThreshold: {{ .Values.controller.livenessProbe.failureThreshold }} + {{- else if .Values.controller.customLivenessProbe }} + livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customLivenessProbe "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.controller.readinessProbe.enabled }} + readinessProbe: + tcpSocket: + port: 6060 + initialDelaySeconds: {{ .Values.controller.readinessProbe.initialDelaySeconds }} + periodSeconds: {{ .Values.controller.readinessProbe.periodSeconds }} + timeoutSeconds: {{ .Values.controller.readinessProbe.timeoutSeconds }} + successThreshold: {{ .Values.controller.readinessProbe.successThreshold }} + failureThreshold: {{ .Values.controller.readinessProbe.failureThreshold }} + {{- else if .Values.controller.customReadinessProbe }} + readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customReadinessProbe "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.controller.startupProbe.enabled }} + startupProbe: + httpGet: + path: {{ .Values.controller.startupProbe.path }} + port: http + initialDelaySeconds: {{ .Values.controller.startupProbe.initialDelaySeconds }} + periodSeconds: {{ .Values.controller.startupProbe.periodSeconds }} + timeoutSeconds: {{ .Values.controller.startupProbe.timeoutSeconds }} + successThreshold: {{ .Values.controller.startupProbe.successThreshold }} + failureThreshold: {{ .Values.controller.startupProbe.failureThreshold }} + {{- else if .Values.controller.customStartupProbe }} + startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.controller.customStartupProbe "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.controller.lifecycleHooks }} + lifecycle: {{- include "common.tplvalues.render" (dict "value" .Values.controller.lifecycleHooks "context" $) | nindent 12 }} + {{- end }} + volumeMounts: + {{- if .Values.controller.extraVolumeMounts }} + {{- include "common.tplvalues.render" (dict "value" .Values.controller.extraVolumeMounts "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.controller.sidecars }} + {{- include "common.tplvalues.render" ( dict "value" .Values.controller.sidecars "context" $) | nindent 8 }} + {{- end }} + volumes: + {{- if .Values.controller.extraVolumes }} + {{- include "common.tplvalues.render" (dict "value" .Values.controller.extraVolumes "context" $) | nindent 8 }} + {{- end }} diff --git a/bitnami/argo-workflows/templates/controller/pdb.yaml b/bitnami/argo-workflows/templates/controller/pdb.yaml new file mode 100644 index 000000000..9b46844a9 --- /dev/null +++ b/bitnami/argo-workflows/templates/controller/pdb.yaml @@ -0,0 +1,27 @@ +{{- if .Values.controller.pdb.enabled }} +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: {{ include "argo-workflows.controller.fullname" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: controller + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- if .Values.controller.pdb.minAvailable }} + minAvailable: {{ .Values.controller.pdb.minAvailable }} + {{- else if .Values.controller.pdb.maxUnavailable }} + maxUnavailable: {{ .Values.controller.pdb.maxUnavailable }} + {{- else }} + minAvailable: 0 + {{- end }} + selector: + matchLabels: {{- include "common.labels.matchLabels" . | nindent 6 }} + app.kubernetes.io/component: controller +{{- end }} diff --git a/bitnami/argo-workflows/templates/controller/service-account.yaml b/bitnami/argo-workflows/templates/controller/service-account.yaml new file mode 100644 index 000000000..d9987729b --- /dev/null +++ b/bitnami/argo-workflows/templates/controller/service-account.yaml @@ -0,0 +1,17 @@ +{{- if .Values.controller.serviceAccount.create }} +apiVersion: v1 +kind: ServiceAccount +metadata: + name: {{ include "argo-workflows.controller.serviceAccountName" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/component: controller + app.kubernetes.io/part-of: argo-workflows + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +automountServiceAccountToken: {{ .Values.controller.serviceAccount.automountServiceAccountToken }} +{{- end }} \ No newline at end of file diff --git a/bitnami/argo-workflows/templates/controller/service.yaml b/bitnami/argo-workflows/templates/controller/service.yaml new file mode 100644 index 000000000..7671faa82 --- /dev/null +++ b/bitnami/argo-workflows/templates/controller/service.yaml @@ -0,0 +1,65 @@ +{{- if or .Values.controller.metrics.enabled .Values.controller.telemetry.enabled }} +apiVersion: v1 +kind: Service +metadata: + name: {{ include "argo-workflows.controller.fullname" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: controller + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if or .Values.controller.service.annotations .Values.commonAnnotations }} + annotations: + {{- if .Values.controller.service.annotations }} + {{- include "common.tplvalues.render" (dict "value" .Values.controller.service.annotations "context" $) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} + {{- end }} +spec: + type: {{ .Values.controller.service.type }} + {{- if and .Values.controller.service.clusterIP (eq .Values.controller.service.type "ClusterIP") }} + clusterIP: {{ .Values.controller.service.clusterIP }} + {{- end }} + {{- if (or (eq .Values.controller.service.type "LoadBalancer") (eq .Values.controller.service.type "NodePort")) }} + externalTrafficPolicy: {{ .Values.controller.service.externalTrafficPolicy | quote }} + {{- end }} + {{ if eq .Values.controller.service.type "LoadBalancer" }} + loadBalancerSourceRanges: {{ .Values.controller.service.loadBalancerSourceRanges }} + {{ end }} + {{- if (and (eq .Values.controller.service.type "LoadBalancer") (not (empty .Values.controller.service.loadBalancerIP))) }} + loadBalancerIP: {{ .Values.controller.service.loadBalancerIP }} + {{- end }} + ports: + {{- if .Values.controller.metrics.enabled }} + - name: tcp-metrics + port: {{ .Values.controller.service.ports.metrics }} + protocol: TCP + targetPort: {{ .Values.controller.containerPorts.metrics }} + {{- if (and (or (eq .Values.controller.service.type "NodePort") (eq .Values.controller.service.type "LoadBalancer")) (not (empty .Values.controller.service.nodePorts.metrics))) }} + nodePort: {{ .Values.controller.service.nodePorts.metrics }} + {{- else if eq .Values.controller.service.type "ClusterIP" }} + nodePort: null + {{- end }} + {{- end }} + {{- if .Values.controller.telemetry.enabled }} + - name: tcp-telemetry + port: {{ .Values.controller.service.ports.telemetry }} + protocol: TCP + targetPort: {{ .Values.controller.containerPorts.telemetry }} + {{- if (and (or (eq .Values.controller.service.type "NodePort") (eq .Values.controller.service.type "LoadBalancer")) (not (empty .Values.controller.service.nodePorts.telemetry))) }} + nodePort: {{ .Values.controller.service.nodePorts.telemetry }} + {{- else if eq .Values.controller.service.type "ClusterIP" }} + nodePort: null + {{- end }} + {{- end }} + {{- if .Values.controller.service.extraPorts }} + {{- include "common.tplvalues.render" (dict "value" .Values.controller.service.extraPorts "context" $) | nindent 4 }} + {{- end }} + selector: {{- include "common.labels.matchLabels" . | nindent 4 }} + app.kubernetes.io/component: controller + sessionAffinity: None +{{- end -}} diff --git a/bitnami/argo-workflows/templates/controller/servicemonitor.yaml b/bitnami/argo-workflows/templates/controller/servicemonitor.yaml new file mode 100644 index 000000000..ac624f39b --- /dev/null +++ b/bitnami/argo-workflows/templates/controller/servicemonitor.yaml @@ -0,0 +1,34 @@ +{{- if and (or .Values.controller.metrics.enabled .Values.controller.telemetry.enabled) .Values.controller.metrics.serviceMonitor.enabled }} +apiVersion: monitoring.coreos.com/v1 +kind: ServiceMonitor +metadata: + name: {{ include "argo-workflows.controller.fullname" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: controller + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + endpoints: + {{- if .Values.controller.metrics.enabled }} + - port: metrics + path: {{ .Values.controller.metrics.path }} + interval: 30s + {{- end }} + {{- if .Values.controller.telemetry.enabled }} + - port: telemetry + path: {{ .Values.controller.telemetry.path }} + interval: 30s + {{- end }} + namespaceSelector: + matchNames: + - {{ .Release.Namespace }} + selector: + matchLabels: {{- include "common.labels.matchLabels" . | nindent 6 }} + app.kubernetes.io/component: controller +{{- end }} diff --git a/bitnami/argo-workflows/templates/controller/workflow-role.yaml b/bitnami/argo-workflows/templates/controller/workflow-role.yaml new file mode 100644 index 000000000..74e935966 --- /dev/null +++ b/bitnami/argo-workflows/templates/controller/workflow-role.yaml @@ -0,0 +1,41 @@ +{{- if .Values.workflows.rbac.create }} +{{- $namespaces := list .Release.Namespace }} +{{- if and (not .Values.rbac.singleNamespace) .Values.controller.workflowNamespaces }} +{{- $namespaces := .Values.controller.workflowNamespaces }} +{{- end }} +{{- range $namespaces }} +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: {{ include "common.names.fullname" $ }}-workflow + namespace: {{ . | quote }} + labels: {{- include "common.labels.standard" $ | nindent 4 }} + app.kubernetes.io/component: controller + app.kubernetes.io/part-of: argo-workflows + {{- if $.Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" $.Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if $.Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $.Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +rules: + - apiGroups: + - "" + resources: + - pods + - configmaps + verbs: + - list + - get + - watch + - patch + - apiGroups: + - "" + resources: + - pods/log + verbs: + - get + - watch + {{- end }} +{{- end }} diff --git a/bitnami/argo-workflows/templates/controller/workflow-rolebinding.yaml b/bitnami/argo-workflows/templates/controller/workflow-rolebinding.yaml new file mode 100644 index 000000000..6e7ff53cc --- /dev/null +++ b/bitnami/argo-workflows/templates/controller/workflow-rolebinding.yaml @@ -0,0 +1,31 @@ +{{- if .Values.workflows.rbac.create }} +{{- $namespaces := list .Release.Namespace }} +{{- if and (not .Values.rbac.singleNamespace) .Values.controller.workflowNamespaces }} +{{- $namespaces := .Values.controller.workflowNamespaces }} +{{- end }} +{{- range $namespaces }} +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: {{ include "common.names.fullname" $ }}-workflow + namespace: {{ . | quote }} + labels: {{- include "common.labels.standard" $ | nindent 4 }} + app.kubernetes.io/component: controller + app.kubernetes.io/part-of: argo-workflows + {{- if $.Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" $.Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if $.Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $.Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: {{ include "common.names.fullname" $ }}-workflow +subjects: + - kind: ServiceAccount + name: {{ include "argo-workflows.workflows.serviceAccountName" $ }} + namespace: {{ . }} +{{- end }} +{{- end }} diff --git a/bitnami/argo-workflows/templates/controller/workflow-serviceaccount.yaml b/bitnami/argo-workflows/templates/controller/workflow-serviceaccount.yaml new file mode 100644 index 000000000..3918a789b --- /dev/null +++ b/bitnami/argo-workflows/templates/controller/workflow-serviceaccount.yaml @@ -0,0 +1,24 @@ +{{- if .Values.workflows.serviceAccount.create -}} +{{- $namespaces := list .Release.Namespace }} +{{- if and (not .Values.rbac.singleNamespace) .Values.controller.workflowNamespaces }} +{{- $namespaces := .Values.controller.workflowNamespaces }} +{{- end }} +{{- range $namespaces }} +--- +apiVersion: v1 +kind: ServiceAccount +metadata: + name: {{ include "argo-workflows.workflows.serviceAccountName" $ }} + namespace: {{ . | quote }} + labels: {{- include "common.labels.standard" $ | nindent 4 }} + app.kubernetes.io/component: controller + app.kubernetes.io/part-of: argo-workflows + {{- if $.Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" $.Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if $.Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $.Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} + {{- end }} +automountServiceAccountToken: {{ .Values.workflows.serviceAccount.automountServiceAccountToken }} +{{- end }} diff --git a/bitnami/argo-workflows/templates/extra-list.yaml b/bitnami/argo-workflows/templates/extra-list.yaml new file mode 100644 index 000000000..6edc87bd9 --- /dev/null +++ b/bitnami/argo-workflows/templates/extra-list.yaml @@ -0,0 +1,4 @@ +{{- range .Values.extraDeploy }} +--- +{{ include "common.tplvalues.render" (dict "value" . "context" $) }} +{{- end }} \ No newline at end of file diff --git a/bitnami/argo-workflows/templates/server/cluster-role.yaml b/bitnami/argo-workflows/templates/server/cluster-role.yaml new file mode 100644 index 000000000..8df841493 --- /dev/null +++ b/bitnami/argo-workflows/templates/server/cluster-role.yaml @@ -0,0 +1,161 @@ +{{- if and .Values.server.enabled .Values.server.rbac.create }} +apiVersion: rbac.authorization.k8s.io/v1 +{{- if .Values.rbac.singleNamespace }} +kind: Role +{{- else }} +kind: ClusterRole +{{- end }} +metadata: + name: {{ include "argo-workflows.server.fullname" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: server + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +rules: + - apiGroups: + - "" + resources: + - configmaps + - events + verbs: + - get + - watch + - list + - apiGroups: + - "" + resources: + - pods + - pods/exec + - pods/log + verbs: + - get + - list + - watch + - delete + {{- if and .Values.server.auth.enabled .Values.server.auth.sso.enabled }} + - apiGroups: + - "" + resources: + - secrets + resourceNames: + - sso + verbs: + - get + - update + - apiGroups: + - "" + resources: + - secrets + verbs: + - create + {{- if .Values.server.auth.sso.rbac }} + - apiGroups: + - "" + resources: + - serviceaccounts + verbs: + - get + - list + {{- end }} + {{- end }} + - apiGroups: + - "" + resources: + - secrets + verbs: + - get + {{- if and .Values.server.auth.enabled .Values.server.auth.sso.enabled }} + {{- if .Values.server.auth.sso.rbac }} + {{- with .Values.server.auth.sso.rbac.secretWhitelist }} + resourceNames: {{- toYaml . | nindent 6 }} + {{- end }} + {{- end }} + {{- end }} + - apiGroups: + - "" + resources: + - events + verbs: + - watch + - create + - patch + {{- if (include "argo-workflows.controller.persistence.enabled" .) }} + - apiGroups: + - "" + resources: + - secrets + resourceNames: + - {{ include "argo-workflows.controller.database.username.secret" . }} + - {{ include "argo-workflows.controller.database.password.secret" . }} + verbs: + - get + {{- end}} + - apiGroups: + - argoproj.io + resources: + - eventsources + - sensors + - workflows + - workfloweventbindings + - workflowtemplates + - cronworkflows + verbs: + - create + - get + - list + - watch + - update + - patch + - delete + - apiGroups: + - dataflow.argoproj.io + resources: + - pipelines + verbs: + - create + - get + - list + - watch + - update + - patch + - delete + +{{- if .Values.server.clusterWorkflowTemplates.enabled }} +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRole +metadata: + name: {{ include "argo-workflows.server.fullname" . }}-cluster-template + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: server + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +rules: + - apiGroups: + - argoproj.io + resources: + - clusterworkflowtemplates + verbs: + - get + - list + - watch + {{- if .Values.server.clusterWorkflowTemplates.enableEditing }} + - create + - update + - patch + - delete + {{- end }} +{{- end }} +{{- end }} diff --git a/bitnami/argo-workflows/templates/server/clusterrolebinding.yaml b/bitnami/argo-workflows/templates/server/clusterrolebinding.yaml new file mode 100644 index 000000000..b5e0c5792 --- /dev/null +++ b/bitnami/argo-workflows/templates/server/clusterrolebinding.yaml @@ -0,0 +1,58 @@ +{{- if and .Values.server.rbac.create .Values.server.enabled -}} +apiVersion: rbac.authorization.k8s.io/v1 +{{- if .Values.rbac.singleNamespace }} +kind: RoleBinding +{{ else }} +kind: ClusterRoleBinding +{{- end }} +metadata: + name: {{ include "argo-workflows.server.fullname" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: server + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +roleRef: + apiGroup: rbac.authorization.k8s.io + {{- if .Values.rbac.singleNamespace }} + kind: Role + {{ else }} + kind: ClusterRole + {{- end }} + name: {{ include "argo-workflows.server.fullname" . }} +subjects: + - kind: ServiceAccount + name: {{ include "argo-workflows.server.serviceAccountName" . }} + namespace: {{ .Release.Namespace | quote }} + +{{- if .Values.server.clusterWorkflowTemplates.enabled }} +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: ClusterRoleBinding +metadata: + name: {{ include "argo-workflows.server.fullname" . }}-cluster-template + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: server + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: ClusterRole + name: {{ include "argo-workflows.server.fullname" . }}-cluster-template +subjects: + - kind: ServiceAccount + name: {{ include "argo-workflows.server.serviceAccountName" . }} + namespace: {{ .Release.Namespace | quote }} +{{- end -}} +{{- end -}} diff --git a/bitnami/argo-workflows/templates/server/deployment.yaml b/bitnami/argo-workflows/templates/server/deployment.yaml new file mode 100644 index 000000000..b5f78a046 --- /dev/null +++ b/bitnami/argo-workflows/templates/server/deployment.yaml @@ -0,0 +1,199 @@ +{{- if .Values.server.enabled }} +apiVersion: {{ include "common.capabilities.deployment.apiVersion" . }} +kind: Deployment +metadata: + name: {{ include "argo-workflows.server.fullname" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: server + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + replicas: {{ .Values.server.replicaCount }} + {{- if .Values.server.updateStrategy }} + strategy: {{- toYaml .Values.server.updateStrategy | nindent 4 }} + {{- end }} + selector: + matchLabels: {{- include "common.labels.matchLabels" . | nindent 6 }} + app.kubernetes.io/component: server + template: + metadata: + annotations: + checksum/config: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }} + {{- if .Values.server.podAnnotations }} + {{- include "common.tplvalues.render" (dict "value" .Values.server.podAnnotations "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.commonAnnotations }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} + labels: {{- include "common.labels.standard" . | nindent 8 }} + app.kubernetes.io/component: server + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.server.podLabels }} + {{- include "common.tplvalues.render" (dict "value" .Values.server.podLabels "context" $) | nindent 8 }} + {{- end }} + spec: + {{- if .Values.server.schedulerName }} + schedulerName: {{ .Values.server.schedulerName | quote }} + {{- end }} + serviceAccountName: {{ include "argo-workflows.server.serviceAccountName" . }} + {{- include "argo-workflows.imagePullSecrets" . | nindent 6 }} + {{- if .Values.server.hostAliases }} + hostAliases: {{- include "common.tplvalues.render" (dict "value" .Values.server.hostAliases "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.server.affinity }} + affinity: {{- include "common.tplvalues.render" ( dict "value" .Values.server.affinity "context" $) | nindent 8 }} + {{- else }} + affinity: + podAffinity: {{- include "common.affinities.pods" (dict "type" .Values.server.podAffinityPreset "component" "server" "context" $) | nindent 10 }} + podAntiAffinity: {{- include "common.affinities.pods" (dict "type" .Values.server.podAntiAffinityPreset "component" "server" "context" $) | nindent 10 }} + nodeAffinity: {{- include "common.affinities.nodes" (dict "type" .Values.server.nodeAffinityPreset.type "key" .Values.server.nodeAffinityPreset.key "values" .Values.server.nodeAffinityPreset.values) | nindent 10 }} + {{- end }} + {{- if .Values.server.nodeSelector }} + nodeSelector: {{- include "common.tplvalues.render" ( dict "value" .Values.server.nodeSelector "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.server.tolerations }} + tolerations: {{- include "common.tplvalues.render" (dict "value" .Values.server.tolerations "context" .) | nindent 8 }} + {{- end }} + {{- if .Values.server.topologySpreadConstraints }} + topologySpreadConstraints: {{- include "common.tplvalues.render" (dict "value" .Values.server.topologySpreadConstraints "context" $) | nindent 8 }} + {{- end }} + {{- if .Values.server.priorityClassName }} + priorityClassName: {{ .Values.server.priorityClassName | quote }} + {{- end }} + {{- if .Values.server.podSecurityContext.enabled }} + securityContext: {{- omit .Values.server.podSecurityContext "enabled" | toYaml | nindent 8 }} + {{- end }} + initContainers: + {{- if .Values.server.initContainers }} + {{- include "common.tplvalues.render" (dict "value" .Values.server.initContainers "context" $) | nindent 8 }} + {{- end }} + containers: + - name: argo-server + image: {{ include "argo-workflows.server.image" . }} + imagePullPolicy: {{ .Values.server.image.pullPolicy }} + {{- if .Values.server.containerSecurityContext.enabled }} + securityContext: {{- omit .Values.server.containerSecurityContext "enabled" | toYaml | nindent 12 }} + {{- end }} + {{- if .Values.server.command }} + command: {{- include "common.tplvalues.render" (dict "value" .Values.server.command "context" $) | nindent 12 }} + {{- end }} + args: + {{- if .Values.server.args }} + {{- include "common.tplvalues.render" (dict "value" .Values.server.args "context" $) | nindent 12 }} + {{- else }} + - server + - --configmap={{ include "argo-workflows.controller.configMapName" . }} + - --secure={{ .Values.server.secure }} + {{- if .Values.rbac.singleNamespace }} + - --namespaced + {{- end }} + {{- if .Values.server.auth.enabled }} + - --auth-mode + - {{ .Values.server.auth.mode }} + {{- end }} + - --port + - {{ .Values.server.containerPorts.web | quote }} + {{- if .Values.server.extraArgs }} + {{- include "common.tplvalues.render" (dict "value" .Values.server.extraArgs "context" $) | nindent 12 }} + {{- end }} + {{- end }} + ports: + - name: web + containerPort: {{ .Values.server.containerPorts.web }} + env: + - name: IN_CLUSTER + value: "true" + - name: ARGO_NAMESPACE + valueFrom: + fieldRef: + apiVersion: v1 + fieldPath: metadata.namespace + - name: BASE_HREF + value: {{ .Values.server.baseHref | quote }} + {{- if .Values.server.extraEnvVars }} + {{- include "common.tplvalues.render" (dict "value" .Values.server.extraEnvVars "context" $) | nindent 12 }} + {{- end }} + envFrom: + {{- if .Values.server.extraEnvVarsCM }} + - configMapRef: + name: {{ include "common.tplvalues.render" (dict "value" .Values.server.extraEnvVarsCM "context" $) }} + {{- end }} + {{- if .Values.server.extraEnvVarsSecret }} + - secretRef: + name: {{ include "common.tplvalues.render" (dict "value" .Values.server.extraEnvVarsSecret "context" $) }} + {{- end }} + {{- if .Values.server.resources }} + resources: {{- toYaml .Values.server.resources | nindent 12 }} + {{- end }} + {{- if .Values.server.livenessProbe.enabled }} + livenessProbe: + httpGet: + path: / + port: {{ .Values.server.containerPorts.web }} + {{- if .Values.server.secure }} + scheme: HTTPS + {{- end }} + initialDelaySeconds: {{ .Values.server.livenessProbe.initialDelaySeconds }} + periodSeconds: {{ .Values.server.livenessProbe.periodSeconds }} + timeoutSeconds: {{ .Values.server.livenessProbe.timeoutSeconds }} + successThreshold: {{ .Values.server.livenessProbe.successThreshold }} + failureThreshold: {{ .Values.server.livenessProbe.failureThreshold }} + {{- else if .Values.server.customLivenessProbe }} + livenessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.server.customLivenessProbe "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.server.readinessProbe.enabled }} + readinessProbe: + httpGet: + path: / + port: {{ .Values.server.containerPorts.web }} + {{- if .Values.server.secure }} + scheme: HTTPS + {{- end }} + initialDelaySeconds: {{ .Values.server.readinessProbe.initialDelaySeconds }} + periodSeconds: {{ .Values.server.readinessProbe.periodSeconds }} + timeoutSeconds: {{ .Values.server.readinessProbe.timeoutSeconds }} + successThreshold: {{ .Values.server.readinessProbe.successThreshold }} + failureThreshold: {{ .Values.server.readinessProbe.failureThreshold }} + {{- else if .Values.server.customReadinessProbe }} + readinessProbe: {{- include "common.tplvalues.render" (dict "value" .Values.server.customReadinessProbe "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.server.startupProbe.enabled }} + startupProbe: + httpGet: + path: {{ .Values.server.startupProbe.path }} + port: http + initialDelaySeconds: {{ .Values.server.startupProbe.initialDelaySeconds }} + periodSeconds: {{ .Values.server.startupProbe.periodSeconds }} + timeoutSeconds: {{ .Values.server.startupProbe.timeoutSeconds }} + successThreshold: {{ .Values.server.startupProbe.successThreshold }} + failureThreshold: {{ .Values.server.startupProbe.failureThreshold }} + {{- else if .Values.server.customStartupProbe }} + startupProbe: {{- include "common.tplvalues.render" (dict "value" .Values.server.customStartupProbe "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.server.lifecycleHooks }} + lifecycle: {{- include "common.tplvalues.render" (dict "value" .Values.server.lifecycleHooks "context" $) | nindent 12 }} + {{- end }} + volumeMounts: + - name: tmp + mountPath: /tmp + {{- if .Values.server.extraVolumeMounts }} + {{- include "common.tplvalues.render" (dict "value" .Values.server.extraVolumeMounts "context" $) | nindent 12 }} + {{- end }} + {{- if .Values.server.sidecars }} + {{- include "common.tplvalues.render" ( dict "value" .Values.server.sidecars "context" $) | nindent 8 }} + {{- end }} + volumes: + - name: tmp + emptyDir: {} + {{- if .Values.server.extraVolumes }} + {{- include "common.tplvalues.render" (dict "value" .Values.server.extraVolumes "context" $) | nindent 8 }} + {{- end }} +{{- end }} diff --git a/bitnami/argo-workflows/templates/server/ingress.yaml b/bitnami/argo-workflows/templates/server/ingress.yaml new file mode 100644 index 000000000..43657e7ef --- /dev/null +++ b/bitnami/argo-workflows/templates/server/ingress.yaml @@ -0,0 +1,70 @@ +{{- if .Values.ingress.enabled }} +apiVersion: {{ include "common.capabilities.ingress.apiVersion" . }} +kind: Ingress +metadata: + name: {{ include "argo-workflows.server.fullname" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/component: server + app.kubernetes.io/part-of: argo-workflows + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if or .Values.ingress.annotations .Values.commonAnnotations .Values.ingress.certManager }} + annotations: + # Ref: https://argoproj.github.io/argo-workflows/argo-server/#ingress + ingress.kubernetes.io/rewrite-target: /$2 + {{- if .Values.server.secure }} + ingress.kubernetes.io/protocol: https # Traefik + nginx.ingress.kubernetes.io/backend-protocol: https # Nginx + {{- end }} + {{- if .Values.ingress.certManager }} + kubernetes.io/tls-acme: "true" + {{- end }} + {{- if .Values.ingress.annotations }} + {{- include "common.tplvalues.render" ( dict "value" .Values.ingress.annotations "context" $) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} + {{- end }} +spec: + {{- if and .Values.ingress.ingressClassName }} + ingressClassName: {{ .Values.ingress.ingressClassName | quote }} + {{- end }} + rules: + {{- if .Values.ingress.hostname }} + - host: {{ .Values.ingress.hostname }} + http: + paths: + {{- if .Values.ingress.extraPaths }} + {{- toYaml .Values.ingress.extraPaths | nindent 10 }} + {{- end }} + - path: {{ .Values.ingress.path }} + {{- if eq "true" (include "common.ingress.supportsPathType" .) }} + pathType: {{ .Values.ingress.pathType }} + {{- end }} + backend: {{- include "common.ingress.backend" (dict "serviceName" (include "argo-workflows.server.fullname" .) "servicePort" "http" "context" $) | nindent 14 }} + {{- end }} + {{- range .Values.ingress.extraHosts }} + - host: {{ .name | quote }} + http: + paths: + - path: {{ default "/" .path }} + {{- if eq "true" (include "common.ingress.supportsPathType" $) }} + pathType: {{ default "ImplementationSpecific" .pathType }} + {{- end }} + backend: {{- include "common.ingress.backend" (dict "serviceName" (include "argo-workflows.server.fullname" $) "servicePort" "http" "context" $) | nindent 14 }} + {{- end }} + {{- if or (and .Values.ingress.tls (or .Values.ingress.certManager .Values.ingress.selfSigned)) .Values.ingress.extraTls }} + tls: + {{- if and .Values.ingress.tls (or .Values.ingress.certManager .Values.ingress.selfSigned) }} + - hosts: + - {{ .Values.ingress.hostname | quote }} + secretName: {{ printf "%s-tls" .Values.ingress.hostname }} + {{- end }} + {{- if .Values.ingress.extraTls }} + {{- include "common.tplvalues.render" (dict "value" .Values.ingress.extraTls "context" $) | nindent 4 }} + {{- end }} + {{- end }} +{{- end }} diff --git a/bitnami/argo-workflows/templates/server/pdb.yaml b/bitnami/argo-workflows/templates/server/pdb.yaml new file mode 100644 index 000000000..b264182d7 --- /dev/null +++ b/bitnami/argo-workflows/templates/server/pdb.yaml @@ -0,0 +1,28 @@ + +{{- if and .Values.server.enabled .Values.server.pdb.enabled -}} +apiVersion: policy/v1beta1 +kind: PodDisruptionBudget +metadata: + name: {{ include "argo-workflows.server.fullname" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: server + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +spec: + {{- if .Values.server.pdb.minAvailable }} + minAvailable: {{ .Values.server.pdb.minAvailable }} + {{- else if .Values.server.pdb.maxUnavailable }} + maxUnavailable: {{ .Values.server.pdb.maxUnavailable }} + {{- else }} + minAvailable: 0 + {{- end }} + selector: + matchLabels: {{- include "common.labels.matchLabels" . | nindent 6 }} + app.kubernetes.io/component: server +{{- end -}} \ No newline at end of file diff --git a/bitnami/argo-workflows/templates/server/service-account.yaml b/bitnami/argo-workflows/templates/server/service-account.yaml new file mode 100644 index 000000000..e06d6e51b --- /dev/null +++ b/bitnami/argo-workflows/templates/server/service-account.yaml @@ -0,0 +1,17 @@ +{{- if .Values.server.serviceAccount.create }} +apiVersion: v1 +kind: ServiceAccount +metadata: + name: {{ include "argo-workflows.server.serviceAccountName" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/component: server + app.kubernetes.io/part-of: argo-workflows + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +automountServiceAccountToken: {{ .Values.server.serviceAccount.automountServiceAccountToken }} +{{- end }} \ No newline at end of file diff --git a/bitnami/argo-workflows/templates/server/service.yaml b/bitnami/argo-workflows/templates/server/service.yaml new file mode 100644 index 000000000..8ad80c080 --- /dev/null +++ b/bitnami/argo-workflows/templates/server/service.yaml @@ -0,0 +1,48 @@ +apiVersion: v1 +kind: Service +metadata: + name: {{ include "argo-workflows.server.fullname" . }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/part-of: argo-workflows + app.kubernetes.io/component: server + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if or .Values.server.service.annotations .Values.commonAnnotations }} + annotations: + {{- if .Values.server.service.annotations }} + {{- include "common.tplvalues.render" (dict "value" .Values.server.service.annotations "context" $) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} + {{- end }} +spec: + {{- if and .Values.server.service.clusterIP (eq .Values.server.service.type "ClusterIP") }} + clusterIP: {{ .Values.server.service.clusterIP }} + {{- end }} + type: {{ .Values.server.service.type }} + {{- if (or (eq .Values.server.service.type "LoadBalancer") (eq .Values.server.service.type "NodePort")) }} + externalTrafficPolicy: {{ .Values.server.service.externalTrafficPolicy | quote }} + {{- end }} + {{- if eq .Values.server.service.type "LoadBalancer" }} + loadBalancerSourceRanges: {{ .Values.server.service.loadBalancerSourceRanges }} + {{- end }} + {{- if (and (eq .Values.server.service.type "LoadBalancer") (not (empty .Values.server.service.loadBalancerIP))) }} + loadBalancerIP: {{ .Values.server.service.loadBalancerIP }} + {{- end }} + ports: + - name: http + port: {{ .Values.server.service.ports.http }} + targetPort: web + {{- if (and (or (eq .Values.server.service.type "NodePort") (eq .Values.server.service.type "LoadBalancer")) (not (empty .Values.server.service.nodePorts.http))) }} + nodePort: {{ .Values.server.service.nodePorts.http }} + {{- else if eq .Values.server.service.type "ClusterIP" }} + nodePort: null + {{- end }} + {{- if .Values.server.service.extraPorts }} + {{- include "common.tplvalues.render" (dict "value" .Values.server.service.extraPorts "context" $) | nindent 4 }} + {{- end }} + selector: {{- include "common.labels.matchLabels" . | nindent 4 }} + app.kubernetes.io/component: server diff --git a/bitnami/argo-workflows/templates/server/tls-secrets.yaml b/bitnami/argo-workflows/templates/server/tls-secrets.yaml new file mode 100644 index 000000000..48687e50b --- /dev/null +++ b/bitnami/argo-workflows/templates/server/tls-secrets.yaml @@ -0,0 +1,48 @@ +{{- if .Values.ingress.enabled }} +{{- if .Values.ingress.secrets }} +{{- range .Values.ingress.secrets }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ .name }} + namespace: {{ $.Release.Namespace | quote }} + labels: {{- include "common.labels.standard" $ | nindent 4 }} + app.kubernetes.io/component: server + app.kubernetes.io/part-of: argo-workflows + {{- if $.Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" $.Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if $.Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" $.Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +type: kubernetes.io/tls +data: + tls.crt: {{ .certificate | b64enc }} + tls.key: {{ .key | b64enc }} +--- +{{- end }} +{{- end }} +{{- if and .Values.ingress.tls .Values.ingress.selfSigned }} +{{- $ca := genCA "server-ca" 365 }} +{{- $cert := genSignedCert .Values.ingress.hostname nil (list .Values.ingress.hostname) 365 $ca }} +apiVersion: v1 +kind: Secret +metadata: + name: {{ printf "%s-tls" .Values.ingress.hostname }} + namespace: {{ .Release.Namespace | quote }} + labels: {{- include "common.labels.standard" . | nindent 4 }} + app.kubernetes.io/component: server + app.kubernetes.io/part-of: argo-workflows + {{- if .Values.commonLabels }} + {{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }} + {{- end }} + {{- if .Values.commonAnnotations }} + annotations: {{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }} + {{- end }} +type: kubernetes.io/tls +data: + tls.crt: {{ $cert.Cert | b64enc | quote }} + tls.key: {{ $cert.Key | b64enc | quote }} + ca.crt: {{ $ca.Cert | b64enc | quote }} +{{- end }} +{{- end }} \ No newline at end of file diff --git a/bitnami/argo-workflows/values.yaml b/bitnami/argo-workflows/values.yaml new file mode 100644 index 000000000..d25a7e6f1 --- /dev/null +++ b/bitnami/argo-workflows/values.yaml @@ -0,0 +1,1141 @@ +## @section Global parameters +## Global Docker image parameters +## Please, note that this will override the image parameters, including dependencies, configured to use the global value +## Current available global Docker image parameters: imageRegistry, imagePullSecrets and storageClass +## @param global.imageRegistry Global Docker image registry +## @param global.imagePullSecrets Global Docker registry secret names as an array +## @param global.storageClass Global StorageClass for Persistent Volume(s) +## +global: + imageRegistry: "" + ## E.g. + ## imagePullSecrets: + ## - myRegistryKeySecretName + ## + imagePullSecrets: [] + storageClass: "" + +## @section Common parameters + +## @param kubeVersion Override Kubernetes version +## +kubeVersion: "" +## @param nameOverride String to partially override common.names.fullname +## +nameOverride: "" +## @param fullnameOverride String to fully override common.names.fullname +## +fullnameOverride: "" +## @param commonLabels Labels to add to all deployed objects +## +commonLabels: {} +## @param commonAnnotations Annotations to add to all deployed objects +## +commonAnnotations: {} +## @param clusterDomain Kubernetes cluster domain name +## +clusterDomain: cluster.local +## @param extraDeploy Array of extra objects to deploy with the release +## +extraDeploy: [] +## @param rbac.singleNamespace Restrict Argo to only deploy into a single namespace by apply Roles and RoleBindings instead of the Cluster equivalents, and start argo-cli with the --namespaced flag. Use it in clusters with strict access policy. +## +rbac: + singleNamespace: false +## @param createAggregateRoles Create Aggregated cluster roles +## +createAggregateRoles: true + +## @section Argo Workflows Server configuration parameters + +## Argo Workflows server (based on the CLI) image +## +server: + ## Bitnami Argo Workflow CLI image + ## ref: https://hub.docker.com/r/bitnami/argo-workflow-cli/tags/ + ## @param server.image.registry server image registry + ## @param server.image.repository server image repository + ## @param server.image.tag server image tag (immutable tags are recommended) + ## @param server.image.pullPolicy server image pull policy + ## @param server.image.pullSecrets server image pull secrets + ## + image: + registry: docker.io + repository: bitnami/argo-workflow-cli + tag: 3.1.13-scratch-r0 + ## Specify a imagePullPolicy + ## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent' + ## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images + ## + pullPolicy: Always + ## Optionally specify an array of imagePullSecrets. + ## Secrets must be manually created in the namespace. + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ + ## e.g: + ## pullSecrets: + ## - myRegistryKeySecretName + ## + pullSecrets: [] + + ## @param server.enabled Enable server deployment + ## + enabled: true + ## @param server.replicaCount Number of server replicas to deploy + ## + replicaCount: 1 + ## Configure extra options for server containers' liveness and readiness probes + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-probes/#configure-probes + ## @param server.livenessProbe.enabled Enable livenessProbe on server nodes + ## @param server.livenessProbe.initialDelaySeconds Initial delay seconds for livenessProbe + ## @param server.livenessProbe.periodSeconds Period seconds for livenessProbe + ## @param server.livenessProbe.timeoutSeconds Timeout seconds for livenessProbe + ## @param server.livenessProbe.failureThreshold Failure threshold for livenessProbe + ## @param server.livenessProbe.successThreshold Success threshold for livenessProbe + ## + livenessProbe: + enabled: true + initialDelaySeconds: 10 + periodSeconds: 20 + timeoutSeconds: 1 + failureThreshold: 3 + successThreshold: 1 + ## @param server.readinessProbe.enabled Enable readinessProbe on server nodes + ## @param server.readinessProbe.initialDelaySeconds Initial delay seconds for readinessProbe + ## @param server.readinessProbe.periodSeconds Period seconds for readinessProbe + ## @param server.readinessProbe.timeoutSeconds Timeout seconds for readinessProbe + ## @param server.readinessProbe.failureThreshold Failure threshold for readinessProbe + ## @param server.readinessProbe.successThreshold Success threshold for readinessProbe + ## + readinessProbe: + enabled: true + initialDelaySeconds: 10 + periodSeconds: 20 + timeoutSeconds: 1 + failureThreshold: 3 + successThreshold: 1 + ## @param server.startupProbe.enabled Enable startupProbe + ## @param server.startupProbe.path Path to check for startupProbe + ## @param server.startupProbe.initialDelaySeconds Initial delay seconds for startupProbe + ## @param server.startupProbe.periodSeconds Period seconds for startupProbe + ## @param server.startupProbe.timeoutSeconds Timeout seconds for startupProbe + ## @param server.startupProbe.failureThreshold Failure threshold for startupProbe + ## @param server.startupProbe.successThreshold Success threshold for startupProbe + ## + startupProbe: + enabled: false + path: / + initialDelaySeconds: 300 + periodSeconds: 10 + timeoutSeconds: 5 + failureThreshold: 6 + successThreshold: 1 + ## @param server.customLivenessProbe Server custom livenessProbe that overrides the default one + ## + customLivenessProbe: {} + ## @param server.customReadinessProbe Server custom readinessProbe that overrides the default one + ## + customReadinessProbe: {} + ## @param server.customStartupProbe Server custom startupProbe that overrides the default one + ## + customStartupProbe: {} + ## server resource requests and limits + ## ref: http://kubernetes.io/docs/user-guide/compute-resources/ + ## @param server.resources.limits The resources limits for the server containers + ## @param server.resources.requests The requested resources for the server containers + ## + resources: + limits: {} + requests: {} + ## Configure Pods Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-pod + ## @param server.podSecurityContext.enabled Enabled server pods' Security Context + ## @param server.podSecurityContext.fsGroup Set server pod's Security Context fsGroup + ## + podSecurityContext: + enabled: true + fsGroup: 1001 + ## Configure Container Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-pod + ## @param server.containerSecurityContext.enabled Enabled server containers' Security Context + ## @param server.containerSecurityContext.runAsUser Set server containers' Security Context runAsUser + ## @param server.containerSecurityContext.runAsNonRoot Set server containers' Security Context runAsNonRoot + ## + containerSecurityContext: + enabled: true + runAsUser: 1001 + runAsNonRoot: true + + ## Create RBAC resources for the Argo workflows server + ## @param server.rbac.create Create RBAC resources for the Argo workflows server + ## + rbac: + create: true + ## @param server.extraArgs Extra arguments for the server command line + ## + extraArgs: "" + ## Enable authentication with the specified mode + ## Ref: https://argoproj.github.io/argo-workflows/argo-server-auth-mode/ + ## + auth: + ## @param server.auth.enabled Enable authentication + ## + enabled: true + ## @param server.auth.mode Set authentication mode. Either `server`, `client` or `sso`. + ## + mode: client + ## SSO configuration when SSO is specified as a server auth mode. + ## All the values are required. SSO is activated by adding --auth-mode=sso to the server command line. + ## @param server.auth.sso.enabled Enable SSO configuration for the server auth mode + ## @param server.auth.sso.issuer Root URL for the OIDC identity provider + ## @param server.auth.sso.clientId.name Name of the secret containing the OIDC client ID + ## @param server.auth.sso.clientId.key Key in the secret to obtain the OIDC client ID + ## @param server.auth.sso.clientSecret.name Name of the secret containing the OIDC client secret + ## @param server.auth.sso.clientSecret.key Key in the secret to obtain the OIDC client secret + ## @param server.auth.sso.redirectUrl The OIDC redirect URL. Should be in the form /oauth2/callback. + ## @param server.auth.sso.rbac.enabled Create RBAC resources for SSO + ## @param server.auth.sso.rbac.secretWhitelist Restricts the secrets that the server can read + ## @param server.auth.sso.scopes Scopes requested from the SSO ID provider + ## + sso: + enabled: false + ## The root URL of the OIDC identity provider. + ## E.g. + ## issuer: "https://accounts.google.com" + issuer: "" + ## Name of a secret and a key in it to retrieve the app OIDC client ID from. + ## + clientId: + name: "" + key: "" + ## Name of a secret and a key in it to retrieve the app OIDC client secret from. + ## + clientSecret: + name: "" + key: "" + ## The OIDC redirect URL. Should be in the form /oauth2/callback. + ## + redirectUrl: "" + ## Create RBAC resources for SSO + rbac: + enabled: true + ## When present, restricts secrets the server can read to a given list. + ## You can use it to restrict the server to only be able to access the + ## service account token secrets that are associated with service accounts + ## used for authorization. + ## + secretWhitelist: [] + ## Scopes requested from the SSO ID provider. The 'groups' scope requests + ## group membership information, which is usually used for authorization + ## decisions. + ## + scopes: [] + + ## @param server.clusterWorkflowTemplates.enabled Create ClusterRole and CRB for the controoler to access ClusterWorkflowTemplates + ## @param server.clusterWorkflowTemplates.enableEditing Give the server permissions to edit ClusterWorkflowTemplates + ## + clusterWorkflowTemplates: + # Create a ClusterRole and CRB for the controller to access ClusterWorkflowTemplates. + enabled: true + enableEditing: true + ## Pod disruption budget configuration + ## Ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb/ + ## @param server.pdb.enabled Create Pod Disruption Budget for the server component + ## @param server.pdb.minAvailable Sets the min number of pods availables for the Pod Disruption Budget + ## @param server.pdb.maxUnavailable Sets the max number of pods unavailable for the Pod Disruption Budget + ## + pdb: + enabled: false + minAvailable: 1 + maxUnavailable: 1 + + ## Run the argo server in "secure" mode. + ## Ref: https://argoproj.github.io/argo-workflows/tls/ + ## @param server.secure Run Argo server in secure mode + ## + secure: false + + ## Base URL for client resources + ## Ref: https://github.com/argoproj/argo-workflows/issues/716#issuecomment-433213190 + ## @param server.baseHref Base href of the Argo Workflows deployment + ## + baseHref: / + + ## Server container port + ## @param server.containerPorts.web argo Server container port + containerPorts: + web: 2746 + + ## ServiceAccount configuration + ## + serviceAccount: + ## @param server.serviceAccount.create Specifies whether a ServiceAccount should be created + ## + create: true + ## @param server.serviceAccount.name The name of the ServiceAccount to use. + ## If not set and create is true, a name is generated using the common.names.fullname template + ## + name: "" + ## @param server.serviceAccount.automountServiceAccountToken Automount service account token for the server service account + automountServiceAccountToken: true + + ## @param server.command Override default container command (useful when using custom images) + ## + command: [] + ## @param server.args Override default container args (useful when using custom images) + ## + args: [] + ## @param server.hostAliases server pods host aliases + ## https://kubernetes.io/docs/concepts/services-networking/add-entries-to-pod-etc-hosts-with-host-aliases/ + ## + hostAliases: [] + ## @param server.podLabels Extra labels for server pods + ## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ + ## + podLabels: {} + ## @param server.podAnnotations Annotations for server pods + ## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ + ## + podAnnotations: {} + ## @param server.podAffinityPreset Pod affinity preset. Ignored if `server.affinity` is set. Allowed values: `soft` or `hard` + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity + ## + podAffinityPreset: "" + ## @param server.podAntiAffinityPreset Pod anti-affinity preset. Ignored if `server.affinity` is set. Allowed values: `soft` or `hard` + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity + ## + podAntiAffinityPreset: soft + ## Node server.affinity preset + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity + ## + nodeAffinityPreset: + ## @param server.nodeAffinityPreset.type Node affinity preset type. Ignored if `server.affinity` is set. Allowed values: `soft` or `hard` + ## + type: "" + ## @param server.nodeAffinityPreset.key Node label key to match. Ignored if `server.affinity` is set + ## + key: "" + ## @param server.nodeAffinityPreset.values Node label values to match. Ignored if `server.affinity` is set + ## E.g. + ## values: + ## - e2e-az1 + ## - e2e-az2 + ## + values: [] + ## @param server.affinity Affinity for server pods assignment + ## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity + ## NOTE: `server.podAffinityPreset`, `server.podAntiAffinityPreset`, and `server.nodeAffinityPreset` will be ignored when it's set + ## + affinity: {} + ## @param server.nodeSelector Node labels for server pods assignment + ## ref: https://kubernetes.io/docs/user-guide/node-selection/ + ## + nodeSelector: {} + ## @param server.tolerations Tolerations for server pods assignment + ## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ + ## + tolerations: [] + ## @param server.updateStrategy.type server statefulset strategy type + ## ref: https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/#update-strategies + ## + updateStrategy: + ## StrategyType + ## Can be set to RollingUpdate or OnDelete + ## + type: RollingUpdate + ## @param server.topologySpreadConstraints Topology spread constraints rely on node labels to identify the topology domain(s) that each Node is in + ## Ref: https://kubernetes.io/docs/concepts/workloads/pods/pod-topology-spread-constraints/ + ## + ## topologySpreadConstraints: + ## - maxSkew: 1 + ## topologyKey: failure-domain.beta.kubernetes.io/zone + ## whenUnsatisfiable: DoNotSchedule + ## + topologySpreadConstraints: [] + ## @param server.schedulerName Alternate scheduler for the server deployment + ## ref: https://kubernetes.io/docs/tasks/administer-cluster/configure-multiple-schedulers/ + ## + schedulerName: "" + ## @param server.priorityClassName server pods' priorityClassName + ## + priorityClassName: "" + ## @param server.lifecycleHooks for the server container(s) to automate configuration before or after startup + ## + lifecycleHooks: {} + ## @param server.extraEnvVars Array with extra environment variables to add to server nodes + ## e.g: + ## extraEnvVars: + ## - name: FOO + ## value: "bar" + ## + extraEnvVars: [] + ## @param server.extraEnvVarsCM Name of existing ConfigMap containing extra env vars for server nodes + ## + extraEnvVarsCM: "" + ## @param server.extraEnvVarsSecret Name of existing Secret containing extra env vars for server nodes + ## + extraEnvVarsSecret: "" + ## @param server.extraVolumes Optionally specify extra list of additional volumes for the server pod(s) + ## + extraVolumes: [] + ## @param server.extraVolumeMounts Optionally specify extra list of additional volumeMounts for the server container(s) + ## + extraVolumeMounts: [] + ## @param server.sidecars Add additional sidecar containers to the server pod(s) + ## e.g: + ## sidecars: + ## - name: your-image-name + ## image: your-image + ## imagePullPolicy: Always + ## ports: + ## - name: portname + ## containerPort: 1234 + ## + sidecars: {} + ## @param server.initContainers Add additional init containers to the server pod(s) + ## ref: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ + ## e.g: + ## initContainers: + ## - name: your-image-name + ## image: your-image + ## imagePullPolicy: Always + ## command: ['sh', '-c', 'echo "hello world"'] + ## + initContainers: {} + + ## Server service parameters + ## + service: + ## @param server.service.type server service type + ## + type: ClusterIP + ## @param server.service.ports.http server service HTTP port + ## + ports: + http: 80 + + ## Node ports to expose + ## @param server.service.nodePorts.http Node port for HTTP + ## NOTE: choose port between <30000-32767> + ## + nodePorts: + http: "" + ## @param server.service.clusterIP server service Cluster IP + ## e.g.: + ## clusterIP: None + ## + clusterIP: "" + ## @param server.service.loadBalancerIP server service Load Balancer IP + ## ref: https://kubernetes.io/docs/concepts/services-networking/service/#type-loadbalancer + ## + loadBalancerIP: "" + ## @param server.service.loadBalancerSourceRanges server service Load Balancer sources + ## ref: https://kubernetes.io/docs/tasks/access-application-cluster/configure-cloud-provider-firewall/#restrict-access-for-loadbalancer-service + ## e.g: + ## loadBalancerSourceRanges: + ## - 10.10.10.0/24 + ## + loadBalancerSourceRanges: [] + ## @param server.service.externalTrafficPolicy server service external traffic policy + ## ref http://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/#preserving-the-client-source-ip + ## + externalTrafficPolicy: Cluster + ## @param server.service.annotations Additional custom annotations for server service + ## + annotations: {} + ## @param server.service.extraPorts Extra port to expose on the server service + ## + extraPorts: [] + +## @section Argo Workflows Controller configuration parameters + +## Argo Workflows Controller +## +controller: + ## Bitnami Argo Workflow Controller image + ## ref: https://hub.docker.com/r/bitnami/argo-workflow-controller/tags/ + ## @param controller.image.registry controller image registry + ## @param controller.image.repository controller image repository + ## @param controller.image.tag controller image tag (immutable tags are recommended) + ## @param controller.image.pullPolicy controller image pull policy + ## @param controller.image.pullSecrets controller image pull secrets + ## + image: + registry: docker.io + repository: bitnami/argo-workflow-controller + tag: 3.1.13-scratch-r0 + ## Specify a imagePullPolicy + ## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent' + ## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images + ## + pullPolicy: IfNotPresent + ## Optionally specify an array of imagePullSecrets. + ## Secrets must be manually created in the namespace. + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ + ## e.g: + ## pullSecrets: + ## - myRegistryKeySecretName + ## + pullSecrets: [] + + ## @param controller.replicaCount Number of controller replicas to deploy + ## + replicaCount: 1 + ## Configure extra options for controller containers' liveness and readiness probes + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-probes/#configure-probes + ## @param controller.livenessProbe.enabled Enable livenessProbe on controller nodes + ## @param controller.livenessProbe.initialDelaySeconds Initial delay seconds for livenessProbe + ## @param controller.livenessProbe.periodSeconds Period seconds for livenessProbe + ## @param controller.livenessProbe.timeoutSeconds Timeout seconds for livenessProbe + ## @param controller.livenessProbe.failureThreshold Failure threshold for livenessProbe + ## @param controller.livenessProbe.successThreshold Success threshold for livenessProbe + ## + livenessProbe: + enabled: true + initialDelaySeconds: 90 + periodSeconds: 60 + timeoutSeconds: 30 + failureThreshold: 3 + successThreshold: 1 + ## @param controller.readinessProbe.enabled Enable readinessProbe on controller nodes + ## @param controller.readinessProbe.initialDelaySeconds Initial delay seconds for readinessProbe + ## @param controller.readinessProbe.periodSeconds Period seconds for readinessProbe + ## @param controller.readinessProbe.timeoutSeconds Timeout seconds for readinessProbe + ## @param controller.readinessProbe.failureThreshold Failure threshold for readinessProbe + ## @param controller.readinessProbe.successThreshold Success threshold for readinessProbe + ## + readinessProbe: + enabled: true + initialDelaySeconds: 30 + periodSeconds: 60 + timeoutSeconds: 30 + failureThreshold: 3 + successThreshold: 1 + ## @param controller.startupProbe.enabled Enable startupProbe + ## @param controller.startupProbe.path Path to check for startupProbe + ## @param controller.startupProbe.initialDelaySeconds Initial delay seconds for startupProbe + ## @param controller.startupProbe.periodSeconds Period seconds for startupProbe + ## @param controller.startupProbe.timeoutSeconds Timeout seconds for startupProbe + ## @param controller.startupProbe.failureThreshold Failure threshold for startupProbe + ## @param controller.startupProbe.successThreshold Success threshold for startupProbe + ## + startupProbe: + enabled: false + path: / + initialDelaySeconds: 300 + periodSeconds: 10 + timeoutSeconds: 5 + failureThreshold: 6 + successThreshold: 1 + ## @param controller.customLivenessProbe Controller custom livenessProbe that overrides the default one + ## + customLivenessProbe: {} + ## @param controller.customReadinessProbe Controller custom readinessProbe that overrides the default one + ## + customReadinessProbe: {} + ## @param controller.customStartupProbe Controller custom startupProbe that overrides the default one + ## + customStartupProbe: {} + ## controller resource requests and limits + ## ref: http://kubernetes.io/docs/user-guide/compute-resources/ + ## @param controller.resources.limits The resources limits for the controller containers + ## @param controller.resources.requests The requested resources for the controller containers + ## + resources: + limits: {} + requests: {} + ## Configure Pods Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-pod + ## @param controller.podSecurityContext.enabled Enabled controller pods' Security Context + ## @param controller.podSecurityContext.fsGroup Set controller pod's Security Context fsGroup + ## + podSecurityContext: + enabled: true + fsGroup: 1001 + ## Configure Container Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-pod + ## @param controller.containerSecurityContext.enabled Enabled controller containers' Security Context + ## @param controller.containerSecurityContext.runAsUser Set controller containers' Security Context runAsUser + ## @param controller.containerSecurityContext.runAsNonRoot Set controller containers' Security Context runAsNonRoot + ## + containerSecurityContext: + enabled: true + runAsUser: 1001 + runAsNonRoot: true + + ## Server container port + ## @param controller.containerPorts.metrics Port to expose controller metrics + ## @param controller.containerPorts.telemetry Port to expose controller telemetry + containerPorts: + metrics: 9090 + telemetry: 8081 + + ## Create RBAC resources for the Argo workflows controller + ## @param controller.rbac.create Create RBAC resources for the Argo workflows controller + ## + rbac: + create: true + + ## Use an existing configmap instead of creating a configmap with the specified parameters + ## @param controller.existingConfigMap + existingConfigMap: "" + + ## @param controller.extraArgs Extra arguments for the controller command line + ## + extraArgs: "" + + ## Controller configmap configuration content. Requires controller.existingConfigmap to be empty. + ## @param controller.config [object] Controller configmap configuration content + config: | + {{- if .Values.controller.instanceID.enabled }} + {{- if .Values.controller.instanceID.useReleaseName }} + instanceID: {{ .Release.Name }} + {{- else }} + instanceID: {{ .Values.controller.instanceID.explicitID }} + {{- end }} + {{- end }} + ## Ref: https://argoproj.github.io/argo-workflows/workflow-executors/ + containerRuntimeExecutor: {{ .Values.controller.containerRuntimeExecutor }} + ## Uncomment to create containerRuntimeExecutors + ## Ref: https://argoproj.github.io/argo-workflows/workflow-executors/ + ## containerRuntimeExecutors: {} + ## How many workflows can be running at the same time + parallelism: + ## Maximun number of workflows running in a namespace + namespaceParallelism: + {{- if or .Values.executor.resources .Values.executor.extraEnvVars .Values.executor.podSecurityContext }} + executor: + {{- if .Values.executor.resources }} + resources: {{- include "common.tplvalues.render" (dict "value" .Values.executor.resources "context" $) | nindent 4 }} + {{- end }} + {{- if .Values.executor.extraEnvVars }} + env: {{- include "common.tplvalues.render" (dict "value" .Values.executor.extraEnvVars "context" $) | nindent 4 }} + {{- end }} + {{- if .Values.executor.podSecurityContext }} + securityContext: {{- include "common.tplvalues.render" (dict "value" .Values.executor.containerSecurityContext "context" $) | nindent 4 }} + {{- if not (eq .Values.controller.containerRuntimeExecutor "docker") }} + ## Docker executor requires to run executor as root + runAsNonRoot: true + {{- end }} + {{- end }} + {{- end }} + ## Uncomment to enable Artofact repository with the provided configuration + ## artifactRepository: + ## archiveLogs: false + ## configuration: {} + {{- if .Values.controller.metrics.enabled }} + metricsConfig: {{- include "common.tplvalues.render" (dict "value" .Values.controller.metrics "context" $) | nindent 4 }} + {{- end }} + {{- if .Values.controller.telemetry.enabled }} + telemetryConfig: {{- include "common.tplvalues.render" (dict "value" .Values.controller.telemetry "context" $) | nindent 4 }} + {{- end }} + {{- if (include "argo-workflows.controller.persistence.enabled" .) }} + persistence: + connectionPool: + maxIdleConns: 100 + maxOpenConns: 0 + nodeStatusOffLoad: false + archive: false + {{- if or .Values.postgresql.enabled (eq .Values.externalDatabase.type "postgresql") }} + postgresql: + {{- else if or .Values.mysql.enabled (eq .Values.externalDatabase.type "mysql") }} + mysql: + {{- end }} + host: {{ include "argo-workflows.controller.database.host" . }} + port: {{ include "argo-workflows.controller.database.port" . }} + database: {{ include "argo-workflows.controller.database" . }} + tableName: argo_workflows + ## the database secrets must be in the same namespace of the controller + userNameSecret: + name: {{ include "argo-workflows.controller.database.username.secret" . }} + key: username + passwordSecret: + name: {{ include "argo-workflows.controller.database.password.secret" . }} + key: {{ include "argo-workflows.controller.database.password.secret.key" . }} + {{- end }} + ## Uncomment to set workflowDefaults + ## Ref: https://argoproj.github.io/argo-workflows/default-workflow-specs/#setting-default-workflow-values + ## workflowDefaults: {} + {{- if and .Values.server.auth.enabled .Values.server.auth.sso.enabled }} + sso: {{- include "common.tplvalues.render" (dict "value" .Values.server.auth.sso "context" $) | nindent 4 }} + {{- end }} + ## Uncomment to set workflowRestrictions + ## Ref: https://argoproj.github.io/argo-workflows/workflow-restrictions/ + ## workflowRestrictions: {} + ## Uncomment to set links + ## Ref: https://argoproj.github.io/argo-workflows/links/ + ## links: {} + + ## Configure the controller to accept only submissions with a matching instanceID attribute + ## @param controller.instanceID.enabled Enable submission filtering based on instanceID attribute. Requires to set instanceID.useReleaseName or instanceID.explicitID + ## @param controller.instanceID.useReleaseName Use the release name to filter submissions + ## @param controller.instanceID.explicitID Filter submissions based on an explicit instance ID + ## + instanceID: + enabled: false + ## NOTE: If `instanceID.enabled` is set to `true` then either `instanceID.userReleaseName` or `instanceID.explicitID` must be defined. + useReleaseName: false + explicitID: "" + + ## Default container runtime that the executor will use. + ## Set as `k8sapi` because `docker` requires privileged access. Also, `k8sapi` allows to runAsNonRoot + ## Ref: https://argoproj.github.io/argo-workflows/workflow-executors/ + ## @param controller.containerRuntimeExecutor Specifies the container runtime for the executor + ## + containerRuntimeExecutor: k8sapi + + ## @param controller.clusterWorkflowTemplates.enabled Whether to create a ClusterRole and Cluster Role Binding to access ClusterWokflowTemplates resources + ## + clusterWorkflowTemplates: + enabled: true + + ## Metrics configuration for the controller + ## @param controller.metrics.enabled Enable controller metrics exporter + ## @param controller.metrics.path Path to expose controller metrics + ## @param controller.metrics.serviceMonitor.enabled Enable prometheus service monitor configuration + ## + metrics: + enabled: false + path: /metrics + serviceMonitor: + enabled: false + ## Telemetry configuration for the controller + ## @param controller.telemetry.enabled Enable telemetry for the controller + ## @param controller.telemetry.path Path to expose telemetry information + ## + telemetry: + enabled: false + path: /telemetry + + ## Number of workflow workers to deploy + ## @param controller.workflowWorkers Number of workflow workers to deploy + ## + workflowWorkers: 32 + ## Number of pod workers to deploy + ## @param controller.podWorkers Number of pod workers to deploy + ## + podWorkers: 32 + + ## Namespaces allowed to run workflows + ## @param controller.workflowNamespaces Namespaces allowed to run workflows + workflowNamespaces: + - default + ## Logging level for the controller + ## @param controller.logging.level Level for the controller logging + ## @param controller.logging.globalLevel Global logging level for the controller + ## + logging: + level: info + globalLevel: "0" + ## Pod disruption budget configuration + ## Ref: https://kubernetes.io/docs/tasks/run-application/configure-pdb/ + ## @param controller.pdb.enabled Create Pod Disruption Budget for the controller component + ## @param controller.pdb.minAvailable Sets the min number of pods availables for the Pod Disruption Budget + ## @param controller.pdb.maxUnavailable Sets the max number of pods unavailable for the Pod Disruption Budget + ## + pdb: + enabled: false + minAvailable: 1 + maxUnavailable: 1 + ## Service Account configuration + ## @param controller.serviceAccount.create Specifies whether a ServiceAccount should be created + ## @param controller.serviceAccount.name Name for the service account + ## + serviceAccount: + create: true + ## If not set and create is true, a name is generated using the common.names.fullname template + ## + name: "" + ## @param controller.serviceAccount.automountServiceAccountToken Automount service account token for the controller service account + automountServiceAccountToken: true + + ## @param controller.command Override default container command (useful when using custom images) + ## + command: [] + ## @param controller.args Override default container args (useful when using custom images) + ## + args: [] + ## @param controller.hostAliases controller pods host aliases + ## https://kubernetes.io/docs/concepts/services-networking/add-entries-to-pod-etc-hosts-with-host-aliases/ + ## + hostAliases: [] + ## @param controller.podLabels Extra labels for controller pods + ## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ + ## + podLabels: {} + ## @param controller.podAnnotations Annotations for controller pods + ## ref: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ + ## + podAnnotations: {} + ## @param controller.podAffinityPreset Pod affinity preset. Ignored if `controller.affinity` is set. Allowed values: `soft` or `hard` + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity + ## + podAffinityPreset: "" + ## @param controller.podAntiAffinityPreset Pod anti-affinity preset. Ignored if `controller.affinity` is set. Allowed values: `soft` or `hard` + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity + ## + podAntiAffinityPreset: soft + ## Node controller.affinity preset + ## ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#node-affinity + ## + nodeAffinityPreset: + ## @param controller.nodeAffinityPreset.type Node affinity preset type. Ignored if `controller.affinity` is set. Allowed values: `soft` or `hard` + ## + type: "" + ## @param controller.nodeAffinityPreset.key Node label key to match. Ignored if `controller.affinity` is set + ## + key: "" + ## @param controller.nodeAffinityPreset.values Node label values to match. Ignored if `controller.affinity` is set + ## E.g. + ## values: + ## - e2e-az1 + ## - e2e-az2 + ## + values: [] + ## @param controller.affinity Affinity for controller pods assignment + ## ref: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity + ## NOTE: `controller.podAffinityPreset`, `controller.podAntiAffinityPreset`, and `controller.nodeAffinityPreset` will be ignored when it's set + ## + affinity: {} + ## @param controller.nodeSelector Node labels for controller pods assignment + ## ref: https://kubernetes.io/docs/user-guide/node-selection/ + ## + nodeSelector: {} + ## @param controller.tolerations Tolerations for controller pods assignment + ## ref: https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/ + ## + tolerations: [] + ## @param controller.updateStrategy.type controller statefulset strategy type + ## ref: https://kubernetes.io/docs/concepts/workloads/controllers/statefulset/#update-strategies + ## + updateStrategy: + ## StrategyType + ## Can be set to RollingUpdate or OnDelete + ## + type: RollingUpdate + ## @param controller.topologySpreadConstraints Topology spread constraints rely on node labels to identify the topology domain(s) that each Node is in + ## Ref: https://kubernetes.io/docs/concepts/workloads/pods/pod-topology-spread-constraints/ + ## + ## topologySpreadConstraints: + ## - maxSkew: 1 + ## topologyKey: failure-domain.beta.kubernetes.io/zone + ## whenUnsatisfiable: DoNotSchedule + ## + topologySpreadConstraints: [] + ## @param controller.schedulerName Alternate scheduler for the server controller + ## ref: https://kubernetes.io/docs/tasks/administer-cluster/configure-multiple-schedulers/ + ## + schedulerName: "" + ## @param controller.priorityClassName controller pods' priorityClassName + ## + priorityClassName: "" + ## @param controller.lifecycleHooks for the controller container(s) to automate configuration before or after startup + ## + lifecycleHooks: {} + ## @param controller.extraEnvVars Array with extra environment variables to add to controller nodes + ## e.g: + ## extraEnvVars: + ## - name: FOO + ## value: "bar" + ## + extraEnvVars: [] + ## @param controller.extraEnvVarsCM Name of existing ConfigMap containing extra env vars for controller nodes + ## + extraEnvVarsCM: "" + ## @param controller.extraEnvVarsSecret Name of existing Secret containing extra env vars for controller nodes + ## + extraEnvVarsSecret: "" + ## @param controller.extraVolumes Optionally specify extra list of additional volumes for the controller pod(s) + ## + extraVolumes: [] + ## @param controller.extraVolumeMounts Optionally specify extra list of additional volumeMounts for the controller container(s) + ## + extraVolumeMounts: [] + ## @param controller.sidecars Add additional sidecar containers to the controller pod(s) + ## e.g: + ## sidecars: + ## - name: your-image-name + ## image: your-image + ## imagePullPolicy: Always + ## ports: + ## - name: portname + ## containerPort: 1234 + ## + sidecars: {} + ## @param controller.initContainers Add additional init containers to the controller pod(s) + ## ref: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ + ## e.g: + ## initContainers: + ## - name: your-image-name + ## image: your-image + ## imagePullPolicy: Always + ## command: ['sh', '-c', 'echo "hello world"'] + ## + initContainers: {} + + ## Controller service parameters + ## + service: + ## @param controller.service.type controller service type + ## + type: ClusterIP + + ## @param controller.service.ports.metrics Metrics port for the controller + ## @param controller.service.ports.telemetry Telemetry port for the controller + ## + ports: + metrics: 8080 + telemetry: 8081 + ## Node ports to expose + ## @param controller.service.nodePorts.metrics Node port for HTTP + ## @param controller.service.nodePorts.telemetry Node port for HTTPS + ## NOTE: choose port between <30000-32767> + ## + nodePorts: + metrics: "" + telemetry: "" + ## @param controller.service.clusterIP controller service Cluster IP + ## e.g.: + ## clusterIP: None + ## + clusterIP: "" + ## @param controller.service.loadBalancerIP controller service Load Balancer IP + ## ref: https://kubernetes.io/docs/concepts/services-networking/service/#type-loadbalancer + ## + loadBalancerIP: "" + ## @param controller.service.loadBalancerSourceRanges controller service Load Balancer sources + ## ref: https://kubernetes.io/docs/tasks/access-application-cluster/configure-cloud-provider-firewall/#restrict-access-for-loadbalancer-service + ## e.g: + ## loadBalancerSourceRanges: + ## - 10.10.10.0/24 + ## + loadBalancerSourceRanges: [] + ## @param controller.service.externalTrafficPolicy controller service external traffic policy + ## ref http://kubernetes.io/docs/tasks/access-application-cluster/create-external-load-balancer/#preserving-the-client-source-ip + ## + externalTrafficPolicy: Cluster + ## @param controller.service.annotations Additional custom annotations for controller service + ## + annotations: {} + ## @param controller.service.extraPorts Extra port to expose on the controller service + ## + extraPorts: [] + +## @section Executor configuration section + +executor: + ## Bitnami Argo Workflow Executor image + ## ref: https://hub.docker.com/r/bitnami/argo-workflow-exec/tags/ + ## @param executor.image.registry executor image registry + ## @param executor.image.repository executor image repository + ## @param executor.image.tag executor image tag (immutable tags are recommended) + ## @param executor.image.pullPolicy executor image pull policy + ## @param executor.image.pullSecrets executor image pull secrets + ## + image: + registry: docker.io + repository: bitnami/argo-workflow-exec + tag: 3.1.13-debian-10-r2 + ## Specify a imagePullPolicy + ## Defaults to 'Always' if image tag is 'latest', else set to 'IfNotPresent' + ## ref: http://kubernetes.io/docs/user-guide/images/#pre-pulling-images + ## + pullPolicy: Always + ## Optionally specify an array of imagePullSecrets. + ## Secrets must be manually created in the namespace. + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ + ## e.g: + ## pullSecrets: + ## - myRegistryKeySecretName + ## + pullSecrets: [] + ## Init container's resource requests and limits + ## ref: http://kubernetes.io/docs/user-guide/compute-resources/ + ## @param executor.resources.limits The resources limits for the init container + ## @param executor.resources.requests The requested resources for the init container + ## + resources: + limits: {} + requests: {} + ## @param executor.extraEnvVars Array with extra environment variables to add to server nodes + ## e.g: + ## extraEnvVars: + ## - name: FOO + ## value: "bar" + ## + extraEnvVars: [] + ## Configure Container Security Context + ## ref: https://kubernetes.io/docs/tasks/configure-pod-container/security-context/#set-the-security-context-for-a-pod + ## @param executor.containerSecurityContext.enabled Enabled executor pods' Security Context + ## @param executor.containerSecurityContext.fsGroup Set executor pod's Security Context fsGroup + ## + containerSecurityContext: + enabled: true + fsGroup: 1001 + +## @section Traffic Exposure Parameters + +## Server ingress parameters +## ref: http://kubernetes.io/docs/user-guide/ingress/ +## +ingress: + ## @param ingress.enabled Enable ingress record generation for server + ## + enabled: false + ## @param ingress.pathType Ingress path type + ## + pathType: ImplementationSpecific + ## @param ingress.apiVersion Force Ingress API version (automatically detected if not set) + ## + apiVersion: "" + ## @param ingress.hostname Default host for the ingress record + ## + hostname: server.local + ## @param ingress.path Default path for the ingress record + ## NOTE: You may need to set this to '/*' in order to use this with ALB ingress controllers + ## + path: / + ## @param ingress.ingressClassName IngressClass that will be be used to implement the Ingress (Kubernetes 1.18+) + ## This is supported in Kubernetes 1.18+ and required if you have more than one IngressClass marked as the default for your cluster. + ## ref: https://kubernetes.io/blog/2020/04/02/improvements-to-the-ingress-api-in-kubernetes-1.18/ + ## + ingressClassName: "" + ## @param ingress.annotations Additional custom annotations for the ingress record + ## NOTE: If `ingress.certManager=true`, annotation `kubernetes.io/tls-acme: "true"` will automatically be added + ## + annotations: {} + ## @param ingress.tls Enable TLS configuration for the host defined at `ingress.hostname` parameter + ## TLS certificates will be retrieved from a TLS secret with name: `{{- printf "%s-tls" .Values.ingress.hostname }}` + ## You can: + ## - Use the `ingress.secrets` parameter to create this TLS secret + ## - Relay on cert-manager to create it by setting `ingress.certManager=true` + ## - Relay on Helm to create self-signed certificates by setting `ingress.selfSigned=true` + ## + tls: false + ## @param ingress.certManager Add the corresponding annotations for cert-manager integration + ## + certManager: false + ## @param ingress.selfSigned Create a TLS secret for this ingress record using self-signed certificates generated by Helm + ## + selfSigned: false + ## @param ingress.extraHosts An array with additional hostname(s) to be covered with the ingress record + ## e.g: + ## extraHosts: + ## - name: server.local + ## path: / + ## + extraHosts: [] + ## @param ingress.extraPaths An array with additional arbitrary paths that may need to be added to the ingress under the main host + ## e.g: + ## extraPaths: + ## - path: /* + ## backend: + ## serviceName: ssl-redirect + ## servicePort: use-annotation + ## + extraPaths: [] + ## @param ingress.extraTls TLS configuration for additional hostname(s) to be covered with this ingress record + ## ref: https://kubernetes.io/docs/concepts/services-networking/ingress/#tls + ## e.g: + ## extraTls: + ## - hosts: + ## - server.local + ## secretName: server.local-tls + ## + extraTls: [] + ## @param ingress.secrets Custom TLS certificates as secrets + ## NOTE: 'key' and 'certificate' are expected in PEM format + ## NOTE: 'name' should line up with a 'secretName' set further up + ## If it is not set and you're using cert-manager, this is unneeded, as it will create a secret for you with valid certificates + ## If it is not set and you're NOT using cert-manager either, self-signed certificates will be created valid for 365 days + ## It is also possible to create and manage the certificates outside of this helm chart + ## Please see README.md for more information + ## e.g: + ## secrets: + ## - name: server.local-tls + ## key: |- + ## -----BEGIN RSA PRIVATE KEY----- + ## ... + ## -----END RSA PRIVATE KEY----- + ## certificate: |- + ## -----BEGIN CERTIFICATE----- + ## ... + ## -----END CERTIFICATE----- + ## + secrets: [] + +## @section Workflows configuration + +workflows: + ## Service account configuration for workflows + ## @param workflows.serviceAccount.create Whether to create a service account to run workflows + ## @param workflows.serviceAccount.name Service account name to run workflows + ## @param workflows.serviceAccount.automountServiceAccountToken Automount service account token for the workflows service account + ## + serviceAccount: + create: false + name: "" + automountServiceAccountToken: true + ## Create RBAC resources to run workflows. + ## A Role and Role Bindding are created per namespace in controller.workflowNamespaces + ## @param workflows.rbac.create Whether to create RBAC resource to run workflows + ## + rbac: + create: true + +## @section PostgreSQL subchart + +## Postgresql subchart configuration +## @param postgresql.enabled Enable PostgreSQL subchart and controller persistence using PostgreSQL +## @param postgresql.service.port PostgreSQL port +## @param postgresql.postgresqlUsername PostgreSQL username +## @param postgresql.postgresqlDatabase PortgreSQL database name +## +postgresql: + enabled: true + service: + port: 5432 + postgresqlUsername: postgres + postgresqlDatabase: bn_argo_workflows + +## @section MySQL subchart + +## Mysql subchart configuration +## @param mysql.enabled Enable MySQL subchart and controller persistence using MySQL +## @param mysql.service.port MySQL port +## @param mysql.auth.username MySQL username +## @param mysql.auth.database MySQL database name +## +mysql: + enabled: false + service: + port: 3306 + auth: + username: mysql + database: bn_argo_workflows + +## @section External Database configuration + +## External Database Configuration +## @param externalDatabase.enabled Enable using externaldatabase and the controller to use persistence with it +## @param externalDatabase.host External Database server host +## @param externalDatabase.port External Database server port +## @param externalDatabase.username External Database username +## @param externalDatabase.password External Database user password +## @param externalDatabase.database External Database database name +## @param externalDatabase.existingSecret The name of an existing secret with database credentials +## @param externalDatabase.type Either postgresql or mysql +## +externalDatabase: + enabled: false + ## Either "postgres" or "mysql" + ## + type: "" + host: localhost + port: 3306 + username: bn_wordpress + password: "" + database: bitnami_wordpress + ## NOTE: Must contain key `database-password` + ## NOTE: When it's set, the `externalDatabase.password` parameter is ignored + ## + existingSecret: ""