diff --git a/charts/kool/.helmignore b/charts/kool/.helmignore new file mode 100644 index 0000000..0e8a0eb --- /dev/null +++ b/charts/kool/.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/charts/kool/Chart.yaml b/charts/kool/Chart.yaml new file mode 100644 index 0000000..49bc2c5 --- /dev/null +++ b/charts/kool/Chart.yaml @@ -0,0 +1,12 @@ +apiVersion: v2 +name: kool +description: kool helm chart +version: 1.0.0 +dependencies: +- name: generic + version: 1.2.1 + repository: https://charts.kool.dev +- name: dind + condition: dind.enabled + version: 1.0.0 + repository: https://charts.kool.dev diff --git a/charts/kool/templates/NOTES.txt b/charts/kool/templates/NOTES.txt new file mode 100644 index 0000000..4e8318a --- /dev/null +++ b/charts/kool/templates/NOTES.txt @@ -0,0 +1,20 @@ +{{- if .Values.generic.ingresses }} + Ingresses: + {{- range $ingress := .Values.generic.ingresses }} + {{- range $host := .hosts }} + {{- range .paths }} + http{{ if $ingress.tls }}s{{ end }}://{{ $host.host }}{{ .path }} + {{- end }} + {{- end }} + {{- end }} +{{- else if .Values.generic.services }} + Services: + {{- $fullName := include "kool.fullname" . -}} + {{- range $service := .Values.generic.services }} + {{- if .fullName }} + {{ .fullName }} + {{- else }} + {{ $fullName }}-{{ .name | default "default" }}:{{ .port }} + {{- end }} + {{- end }} +{{- end }} diff --git a/charts/kool/templates/_helpers.tpl b/charts/kool/templates/_helpers.tpl new file mode 100644 index 0000000..b41c254 --- /dev/null +++ b/charts/kool/templates/_helpers.tpl @@ -0,0 +1,25 @@ +{{/* vim: set filetype=mustache: */}} +{{/* +Expand the name of the chart. +*/}} +{{- define "kool.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). +If release name contains chart name it will be used as a full name. +*/}} +{{- define "kool.fullname" -}} +{{- if .Values.fullnameOverride }} +{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }} +{{- else }} +{{- $name := default .Chart.Name .Values.nameOverride }} +{{- if contains $name .Release.Name }} +{{- .Release.Name | trunc 63 | trimSuffix "-" }} +{{- else }} +{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }} +{{- end }} +{{- end }} +{{- end }} diff --git a/charts/kool/values.yaml b/charts/kool/values.yaml new file mode 100644 index 0000000..2684cf5 --- /dev/null +++ b/charts/kool/values.yaml @@ -0,0 +1,37 @@ +dind: + enabled: true + + generic: + services: + default: + fullName: dind + +generic: + nameOverride: kool + + containers: + kool: + image: + repository: kooldev/kool + pullPolicy: Always + tag: 1.0 + env: + - name: "DOCKER_HOST" + value: "tcp://dind:2375" + # volumeMounts: + # - name: bins + # mountPath: "/kool" + + # configMaps: + # - name: bins + # files: + # bash_1: | + # ... + # bash_2: | + # ... + + # volumes: + # - name: bins + # configMap: + # name: bins + # defaultMode: 0755