argocd-helm/charts/argo/templates/apply-workflow-crd-job.yaml
Justin Nauman b6588e85b8 Chart Grooming (#14)
* Chart Grooming

- Changed the default `workflow-controller` installation to use the `ServiceAccount` that is created and bound.
- Customized the instanceID logic:
  - No longer defaults to installed (this was very difficult to see/understand when coming from starter tutorials)
  - Kept logic to allow for release name or explicit mappings but changed structure a bit
- Added in optional configuration for:
  - CRD Install hook's ServiceAccount to allow clean install if your
  default roles aren't privledged
  - Optional Pod and Service annotations
  - Controller logging level configuration
- Minio Customizations
  - Changed the Secret configuration to properly represent the path of a secret instead of the actual contents
  - Changed the names of the secret and service that are represented to mirror that of the underlying chart

* Adding in role bindings for minio secrets if installed
2018-08-16 00:39:27 -07:00

19 lines
557 B
YAML

apiVersion: batch/v1
kind: Job
metadata:
name: {{ .Release.Name }}-apply-workflow-crd
annotations:
helm.sh/hook: pre-install
helm.sh/hook-delete-policy: hook-succeeded
spec:
backoffLimit: 5
activeDeadlineSeconds: 100
template:
spec:
serviceAccountName: {{ .Values.init.serviceAccount | quote }}
containers:
- name: kubectl-apply
image: lachlanevenson/k8s-kubectl
command: ["/bin/sh"]
args: ["-c", 'echo ''{{- include "workflow-crd-json" .}}'' | kubectl apply -f -']
restartPolicy: Never