Skip to content

Instantly share code, notes, and snippets.

@JonJam
Created March 7, 2018 08:33
Show Gist options
  • Save JonJam/a28a4f5eef1fa441baaaa50e0d904def to your computer and use it in GitHub Desktop.
Save JonJam/a28a4f5eef1fa441baaaa50e0d904def to your computer and use it in GitHub Desktop.
k8s helm - _helpers
{{/* vim: set filetype=mustache: */}}
{{/*
Expand the name of the chart.
*/}}
{{- define "themeparks-bot.name" -}}
{{- .Chart.Name -}}
{{- 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 "themeparks-bot.fullname" -}}
{{- printf "%s-%s" .Release.Name .Chart.Name | trunc 63 | trimSuffix "-" -}}
{{- end -}}
{{/*
Create chart name and version as used by the chart label.
*/}}
{{- define "themeparks-bot.chart" -}}
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
{{- end -}}
{{/*
Create dns name for redis.
*/}}
{{- define "redis.dns" -}}
{{- printf "%s-redis-ha-master-svc.%s" .Release.Name .Release.Namespace -}}
{{- end -}}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment