diff --git a/charts/argo-workflows/Chart.yaml b/charts/argo-workflows/Chart.yaml index b2ea75251..280fe34c4 100644 --- a/charts/argo-workflows/Chart.yaml +++ b/charts/argo-workflows/Chart.yaml @@ -3,7 +3,7 @@ appVersion: v3.3.9 name: argo-workflows description: A Helm chart for Argo Workflows type: application -version: 0.17.1 +version: 0.17.2 icon: https://raw.githubusercontent.com/argoproj/argo-workflows/master/docs/assets/argo.png home: https://github.com/argoproj/argo-helm sources: @@ -13,4 +13,4 @@ maintainers: url: https://argoproj.github.io/ annotations: artifacthub.io/changes: | - - "[Changed]: Helm chart maintainers standardized to argoproj" + - "[Changed]: Moved crds folder in the templates folder and added crds variable in the values.yaml file" diff --git a/charts/argo-workflows/README.md b/charts/argo-workflows/README.md index 7d14a64f2..74accc3b2 100644 --- a/charts/argo-workflows/README.md +++ b/charts/argo-workflows/README.md @@ -15,6 +15,12 @@ A few options are: ## Usage Notes +### Custom resource definitions + +Some users would prefer to install the CRDs _outside_ of the chart. You can disable the CRD installation of this chart by using `--set crds.install=false` when installing the chart. + +You can install the CRDs manually from `templates/crds` folder. + ### Workflow controller This chart defaults to setting the `controller.instanceID.enabled` to `false` now, which means the deployed controller will act upon any workflow deployed to the cluster. If you would like to limit the behavior and deploy multiple workflow controllers, please use the `controller.instanceID.enabled` attribute along with one of its configuration options to set the `instanceID` of the workflow controller to be properly scoped for your needs. @@ -42,6 +48,9 @@ Fields to note: | Key | Type | Default | Description | |-----|------|---------|-------------| | createAggregateRoles | bool | `true` | Create clusterroles that extend existing clusterroles to interact with argo-cd crds | +| crds.install | bool `true` | Install and update CRDs | +| crds.keep | bool `true` | Keep CRDs on chart uninstallation | +| crds.annotations | object `{}` | Additional annotations to be added to the CRDs | | fullnameOverride | string | `nil` | String to fully override "argo-workflows.fullname" template | | images.pullPolicy | string | `"Always"` | imagePullPolicy to apply to all containers | | images.pullSecrets | list | `[]` | Secrets with credentials to pull images from a private registry | diff --git a/charts/argo-workflows/crds/argoproj.io_clusterworkflowtemplates.yaml b/charts/argo-workflows/templates/crds/argoproj.io_clusterworkflowtemplates.yaml similarity index 78% rename from charts/argo-workflows/crds/argoproj.io_clusterworkflowtemplates.yaml rename to charts/argo-workflows/templates/crds/argoproj.io_clusterworkflowtemplates.yaml index 889dfe2f5..145245601 100644 --- a/charts/argo-workflows/crds/argoproj.io_clusterworkflowtemplates.yaml +++ b/charts/argo-workflows/templates/crds/argoproj.io_clusterworkflowtemplates.yaml @@ -1,7 +1,15 @@ +{{- if .Values.crds.install }} apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: name: clusterworkflowtemplates.argoproj.io + annotations: + {{- if .Values.crds.keep }} + "helm.sh/resource-policy": keep + {{- end }} + {{- with .Values.crds.annotations }} + {{- toYaml . | nindent 4 }} + {{- end }} spec: group: argoproj.io names: @@ -34,3 +42,4 @@ spec: type: object served: true storage: true +{{- end }} \ No newline at end of file diff --git a/charts/argo-workflows/crds/argoproj.io_cronworkflows.yaml b/charts/argo-workflows/templates/crds/argoproj.io_cronworkflows.yaml similarity index 80% rename from charts/argo-workflows/crds/argoproj.io_cronworkflows.yaml rename to charts/argo-workflows/templates/crds/argoproj.io_cronworkflows.yaml index 812cf1143..d1856613c 100644 --- a/charts/argo-workflows/crds/argoproj.io_cronworkflows.yaml +++ b/charts/argo-workflows/templates/crds/argoproj.io_cronworkflows.yaml @@ -1,7 +1,15 @@ +{{- if .Values.crds.install }} apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: name: cronworkflows.argoproj.io + annotations: + {{- if .Values.crds.keep }} + "helm.sh/resource-policy": keep + {{- end }} + {{- with .Values.crds.annotations }} + {{- toYaml . | nindent 4 }} + {{- end }} spec: group: argoproj.io names: @@ -38,3 +46,4 @@ spec: type: object served: true storage: true +{{- end }} \ No newline at end of file diff --git a/charts/argo-workflows/crds/argoproj.io_workfloweventbindings.yaml b/charts/argo-workflows/templates/crds/argoproj.io_workfloweventbindings.yaml similarity index 77% rename from charts/argo-workflows/crds/argoproj.io_workfloweventbindings.yaml rename to charts/argo-workflows/templates/crds/argoproj.io_workfloweventbindings.yaml index 22e2ecf0f..549fa2b75 100644 --- a/charts/argo-workflows/crds/argoproj.io_workfloweventbindings.yaml +++ b/charts/argo-workflows/templates/crds/argoproj.io_workfloweventbindings.yaml @@ -1,7 +1,15 @@ +{{- if .Values.crds.install }} apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: name: workfloweventbindings.argoproj.io + annotations: + {{- if .Values.crds.keep }} + "helm.sh/resource-policy": keep + {{- end }} + {{- with .Values.crds.annotations }} + {{- toYaml . | nindent 4 }} + {{- end }} spec: group: argoproj.io names: @@ -33,3 +41,4 @@ spec: type: object served: true storage: true +{{- end }} \ No newline at end of file diff --git a/charts/argo-workflows/crds/argoproj.io_workflows.yaml b/charts/argo-workflows/templates/crds/argoproj.io_workflows.yaml similarity index 83% rename from charts/argo-workflows/crds/argoproj.io_workflows.yaml rename to charts/argo-workflows/templates/crds/argoproj.io_workflows.yaml index 6e646adc7..ab16fc223 100644 --- a/charts/argo-workflows/crds/argoproj.io_workflows.yaml +++ b/charts/argo-workflows/templates/crds/argoproj.io_workflows.yaml @@ -1,7 +1,15 @@ +{{- if .Values.crds.install }} apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: name: workflows.argoproj.io + annotations: + {{- if .Values.crds.keep }} + "helm.sh/resource-policy": keep + {{- end }} + {{- with .Values.crds.annotations }} + {{- toYaml . | nindent 4 }} + {{- end }} spec: group: argoproj.io names: @@ -48,3 +56,4 @@ spec: served: true storage: true subresources: {} +{{- end }} \ No newline at end of file diff --git a/charts/argo-workflows/crds/argoproj.io_workflowtaskresults.yaml b/charts/argo-workflows/templates/crds/argoproj.io_workflowtaskresults.yaml similarity index 98% rename from charts/argo-workflows/crds/argoproj.io_workflowtaskresults.yaml rename to charts/argo-workflows/templates/crds/argoproj.io_workflowtaskresults.yaml index 84d60f3e7..892c47ded 100644 --- a/charts/argo-workflows/crds/argoproj.io_workflowtaskresults.yaml +++ b/charts/argo-workflows/templates/crds/argoproj.io_workflowtaskresults.yaml @@ -1,7 +1,15 @@ +{{- if .Values.crds.install }} apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: name: workflowtaskresults.argoproj.io + annotations: + {{- if .Values.crds.keep }} + "helm.sh/resource-policy": keep + {{- end }} + {{- with .Values.crds.annotations }} + {{- toYaml . | nindent 4 }} + {{- end }} spec: group: argoproj.io names: @@ -423,3 +431,4 @@ spec: type: object served: true storage: true +{{- end }} \ No newline at end of file diff --git a/charts/argo-workflows/crds/argoproj.io_workflowtasksets.yaml b/charts/argo-workflows/templates/crds/argoproj.io_workflowtasksets.yaml similarity index 80% rename from charts/argo-workflows/crds/argoproj.io_workflowtasksets.yaml rename to charts/argo-workflows/templates/crds/argoproj.io_workflowtasksets.yaml index 22cf52b19..6d01f979b 100644 --- a/charts/argo-workflows/crds/argoproj.io_workflowtasksets.yaml +++ b/charts/argo-workflows/templates/crds/argoproj.io_workflowtasksets.yaml @@ -1,7 +1,15 @@ +{{- if .Values.crds.install }} apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: name: workflowtasksets.argoproj.io + annotations: + {{- if .Values.crds.keep }} + "helm.sh/resource-policy": keep + {{- end }} + {{- with .Values.crds.annotations }} + {{- toYaml . | nindent 4 }} + {{- end }} spec: group: argoproj.io names: @@ -39,3 +47,4 @@ spec: storage: true subresources: status: {} +{{- end }} \ No newline at end of file diff --git a/charts/argo-workflows/crds/argoproj.io_workflowtemplates.yaml b/charts/argo-workflows/templates/crds/argoproj.io_workflowtemplates.yaml similarity index 77% rename from charts/argo-workflows/crds/argoproj.io_workflowtemplates.yaml rename to charts/argo-workflows/templates/crds/argoproj.io_workflowtemplates.yaml index 8165ec25b..e71c73f4e 100644 --- a/charts/argo-workflows/crds/argoproj.io_workflowtemplates.yaml +++ b/charts/argo-workflows/templates/crds/argoproj.io_workflowtemplates.yaml @@ -1,7 +1,15 @@ +{{- if .Values.crds.install }} apiVersion: apiextensions.k8s.io/v1 kind: CustomResourceDefinition metadata: name: workflowtemplates.argoproj.io + annotations: + {{- if .Values.crds.keep }} + "helm.sh/resource-policy": keep + {{- end }} + {{- with .Values.crds.annotations }} + {{- toYaml . | nindent 4 }} + {{- end }} spec: group: argoproj.io names: @@ -33,3 +41,4 @@ spec: type: object served: true storage: true +{{- end }} \ No newline at end of file diff --git a/charts/argo-workflows/values.yaml b/charts/argo-workflows/values.yaml index da69440a4..eda3ffc5d 100644 --- a/charts/argo-workflows/values.yaml +++ b/charts/argo-workflows/values.yaml @@ -11,6 +11,15 @@ images: ## Ref: https://kubernetes.io/docs/reference/access-authn-authz/rbac/#aggregated-clusterroles createAggregateRoles: true +## Custom resource configuration +crds: + # -- Install and upgrade CRDs + install: true + # -- Keep CRDs on chart uninstall + keep: true + # -- Annotations to be added to all CRDs + annotations: {} + # -- String to partially override "argo-workflows.fullname" template nameOverride: