Create agro helm chart

pull/4/head
Alexander Matyushentsev 2018-01-02 16:45:35 -08:00
parent 5456fd1e8b
commit b2f8f0c283
12 changed files with 175 additions and 0 deletions

1
charts/argo/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
charts

21
charts/argo/.helmignore Normal file
View File

@ -0,0 +1,21 @@
# 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
*~
# Various IDEs
.project
.idea/
*.tmproj

4
charts/argo/Chart.yaml Normal file
View File

@ -0,0 +1,4 @@
apiVersion: v1
description: A Helm chart for Kubernetes
name: argo
version: 0.1.0

View File

@ -0,0 +1,6 @@
dependencies:
- name: minio
repository: https://kubernetes-charts.storage.googleapis.com/
version: 0.4.3
digest: sha256:b67924f37f043c1fa76d5eeae48fc89bfb66d4f181bc470e321db4054959e63e
generated: 2018-01-02T13:30:37.422817-08:00

View File

@ -0,0 +1,5 @@
dependencies:
- name: minio
version: 0.4.3
repository: https://kubernetes-charts.storage.googleapis.com/
condition: installMinio

View File

@ -0,0 +1,19 @@
1. Make sure Workflow CRD is created by running:
echo '{"apiVersion": "apiextensions.k8s.io/v1beta1","kind": "CustomResourceDefinition", "metadata": {"name": "workflows.argoproj.io"},
"spec": {"group": "argoproj.io","names":
{"kind": "Workflow","listKind": "WorkflowList","plural": "workflows","shortNames": ["wf"],"singular": "workflow"}, "scope": "Namespaced","version": "v1alpha1"}}' \
| kubectl create -f -
2. Get Argo UI external IP/domain by running:
kubectl get services -o wide | grep {{ .Release.Name }}-{{ .Values.uiName }}
{{ if .Values.installMinio }}
3. Access Minio UI and create bucket '{{ .Values.minioBucketName }}'. Minio UI is available on port 9000 and available via external URL. URL might be retrieved using following
command:
kubectl get services -o wide | grep {{ .Release.Name }}-minio-svc
{{ end }}

View File

@ -0,0 +1,16 @@
{{/* vim: set filetype=mustache: */}}
{{/*
Expand the name of the chart.
*/}}
{{- define "name" -}}
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" -}}
{{- end -}}
{{/*
Create a default fully qualified app name.
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
*/}}
{{- define "fullname" -}}
{{- $name := default .Chart.Name .Values.nameOverride -}}
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}}
{{- end -}}

View File

@ -0,0 +1,21 @@
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: {{ .Release.Name }}-{{ .Values.uiName}}
labels:
chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
spec:
template:
metadata:
labels:
app: {{ .Release.Name }}-{{ .Values.uiName}}
release: {{ .Release.Name }}
spec:
containers:
- name: ui
image: "{{ .Values.imagesNamespace }}/{{ .Values.uiImage }}:{{ .Values.imagesTag }}"
env:
- name: IN_CLUSTER
value: "true"

View File

@ -0,0 +1,17 @@
apiVersion: v1
kind: Service
metadata:
name: {{ .Release.Name }}-{{ .Values.uiName}}
labels:
chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
spec:
ports:
- port: 80
protocol: TCP
targetPort: 8001
selector:
app: {{ .Release.Name }}-{{ .Values.uiName}}
sessionAffinity: None
type: LoadBalancer

View File

@ -0,0 +1,24 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ .Release.Name }}-{{ .Values.controllerName}}-configmap
labels:
chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
data:
config: |
artifactRepository:
{{ if .Values.installMinio }}
s3:
accessKeySecret:
key: accesskey
name: {{ .Release.Name }}-minio-user
bucket: {{ .Values.minioBucketName }}
endpoint: {{ .Release.Name }}-minio-svc:9000
insecure: true
secretKeySecret:
key: secretkey
name: {{ .Release.Name }}-minio-user
{{ end }}
executorImage: "{{ .Values.imagesNamespace }}/{{ .Values.executorImage }}:{{ .Values.imagesTag }}"

View File

@ -0,0 +1,27 @@
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: {{ .Release.Name }}-{{ .Values.controllerName}}
labels:
app: {{ .Release.Name }}-{{ .Values.controllerName}}
chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
release: {{ .Release.Name }}
heritage: {{ .Release.Service }}
spec:
template:
metadata:
labels:
app: {{ .Release.Name }}-{{ .Values.controllerName}}
release: {{ .Release.Name }}
spec:
containers:
- name: controller
image: "{{ .Values.imagesNamespace }}/{{ .Values.controllerImage }}:{{ .Values.imagesTag }}"
command: [ "workflow-controller" ]
args: ["--configmap", "{{ .Release.Name }}-{{ .Values.controllerName}}-configmap"]
env:
- name: ARGO_NAMESPACE
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.namespace

14
charts/argo/values.yaml Normal file
View File

@ -0,0 +1,14 @@
imagesNamespace: argoproj
controllerImage: workflow-controller
uiImage: argoui
imagesTag: latest
controllerName: workflow-controller
enableWebConsole: false
executorImage: argoexec
uiName: ui
crdVersion: v1alpha1
instanceID:
serviceAccount:
installMinio: true
minioBucketName: argo-artifacts