diff --git a/charts/argo/Chart.yaml b/charts/argo/Chart.yaml index 1ffb5594..8ea0a280 100644 --- a/charts/argo/Chart.yaml +++ b/charts/argo/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v1 -appVersion: "v2.3.0" +appVersion: "v2.4.2" description: A Helm chart for Argo Workflows name: argo -version: 0.5.4 +version: 0.6.0 icon: https://raw.githubusercontent.com/argoproj/argo/master/argo.png diff --git a/charts/argo/README.md b/charts/argo/README.md index ac2c234d..348a0e0a 100644 --- a/charts/argo/README.md +++ b/charts/argo/README.md @@ -8,7 +8,7 @@ If you want your deployment of this helm chart to most closely match the [argo C This chart uses an install hook to configure the CRD definition. Installation of CRDs is a somewhat privileged process in itself and in RBAC enabled clusters the `default` service account for namespaces does not typically have the ability to do create these. A few options are: -- Setup the CRD yourself manually and use the `--no-hooks` options of `helm install` +- Setup the CRD yourself manually and use `--set installCRD=false` when installing the helm chart. Find the CRDs in the [argo codebase](https://raw.githubusercontent.com/argoproj/argo/master/manifests/base/crds/workflow-crd.yaml) - Manually create a ServiceAccount in the Namespace which your release will be deployed w/ appropriate bindings to perform this action and set the `init.serviceAccount` attribute - Augment the `default` ServiceAccount permissions in the Namespace in which your Release is deployed to have the appropriate permissions diff --git a/charts/argo/templates/ui-cluster-role.yaml b/charts/argo/templates/ui-cluster-role.yaml index 2e3c975e..7540e8fd 100644 --- a/charts/argo/templates/ui-cluster-role.yaml +++ b/charts/argo/templates/ui-cluster-role.yaml @@ -1,4 +1,4 @@ -{{- if .Values.ui.enabled -}} +{{- if .Values.ui.enabled }} apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRole metadata: @@ -24,8 +24,9 @@ rules: - argoproj.io resources: - workflows + - workflowtemplates verbs: - get - list - watch - {{- end -}} +{{- end }} diff --git a/charts/argo/templates/workflow-aggregate-roles.yaml b/charts/argo/templates/workflow-aggregate-roles.yaml index 5164ade0..a6d3a7dd 100644 --- a/charts/argo/templates/workflow-aggregate-roles.yaml +++ b/charts/argo/templates/workflow-aggregate-roles.yaml @@ -14,11 +14,12 @@ rules: resources: - workflows - workflows/finalizers + - workflowtemplates + - workflowtemplates/finalizers verbs: - get - list - watch - --- apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRole @@ -35,6 +36,8 @@ rules: resources: - workflows - workflows/finalizers + - workflowtemplates + - workflowtemplates/finalizers verbs: - create - delete @@ -44,7 +47,6 @@ rules: - patch - update - watch - --- apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRole @@ -61,6 +63,8 @@ rules: resources: - workflows - workflows/finalizers + - workflowtemplates + - workflowtemplates/finalizers verbs: - create - delete diff --git a/charts/argo/templates/workflow-controller-clusterrole.yaml b/charts/argo/templates/workflow-controller-clusterrole.yaml index db17f777..57013987 100644 --- a/charts/argo/templates/workflow-controller-clusterrole.yaml +++ b/charts/argo/templates/workflow-controller-clusterrole.yaml @@ -42,4 +42,21 @@ rules: - watch - update - patch - - delete \ No newline at end of file + - delete +- apiGroups: + - argoproj.io + resources: + - workflowtemplates + - workflowtemplates/finalizers + verbs: + - get + - list + - watch +- apiGroups: + - "" + resources: + - serviceaccounts + verbs: + - get + - list + diff --git a/charts/argo/templates/workflow-crd.yaml b/charts/argo/templates/workflow-crd.yaml index 64a77d7f..75aa6154 100644 --- a/charts/argo/templates/workflow-crd.yaml +++ b/charts/argo/templates/workflow-crd.yaml @@ -1,3 +1,4 @@ +{{- if .installCRD }} apiVersion: apiextensions.k8s.io/v1beta1 kind: CustomResourceDefinition metadata: @@ -14,3 +15,4 @@ spec: plural: workflows shortNames: - wf +{{- end }} diff --git a/charts/argo/templates/workflow-template-crd.yaml b/charts/argo/templates/workflow-template-crd.yaml new file mode 100644 index 00000000..0ecc8cd6 --- /dev/null +++ b/charts/argo/templates/workflow-template-crd.yaml @@ -0,0 +1,18 @@ +{{- if .installCRD }} +apiVersion: apiextensions.k8s.io/v1beta1 +kind: CustomResourceDefinition +metadata: + name: workflowtemplates.argoproj.io + annotations: + helm.sh/hook: crd-install + helm.sh/hook-delete-policy: before-hook-creation +spec: + group: argoproj.io + version: v1alpha1 + scope: Namespaced + names: + kind: WorkflowTemplate + plural: workflowtemplates + shortNames: + - wftmpl +{{- end }} diff --git a/charts/argo/values.yaml b/charts/argo/values.yaml index ff23183c..5a5cc114 100644 --- a/charts/argo/values.yaml +++ b/charts/argo/values.yaml @@ -4,9 +4,10 @@ images: ui: argoui executor: argoexec pullPolicy: Always - tag: v2.3.0 + tag: v2.4.2 crdVersion: v1alpha1 +installCRD: true init: # By default the installation will not set an explicit one, which will mean it uses `default` for the namespace the chart is