argocd-helm/charts/argo-cd/templates/_helpers.tpl
Liviu Costea db30d36879 Helm chart for ArgoCD (#34)
* Add application controller resources

First chart version for argo-cd
added the new labels recommeneded for k8

* Add repo server resources

Use legacy label and new one for application controller selectors
Set labels for deployment for easier discovery

* Configure git repositories, helm chart museums and dex connectors

This way argo-cd could be configured to update itself via helm

* Parameterize the rbac configmap

* Parameterize webhook secrets

* Parameterize server deployment and set services with the labels

* Add service account, role and rolebinding for server deployment

* Clean the old label, use only latest recommendations

Follow the ideas and changes of https://github.com/argoproj/argo-cd/pull/1035

* Fix var naming issues

* Fix server service incorrect ports

* Install crds with helm hook

* Enable cluster admin accessby default

Default installation will allow installing apps in the current cluster without
inputted credentials. For other clusters inputted credentials will be needed

* Parameterize the dex server

* Harcode resource names because code expects them this way

Some resource names and application urls are hardcoded in code with these
names. So they can't be parameterized.

* Create the ingress with tls passthrough support

Tls is terminated on the ArgoCD server, not on ingress

* Fix typo on application controller sa

* Add notes on how to connect to server UI after installation
2019-02-13 14:22:11 -08:00

32 lines
1 KiB
Smarty

{{/* vim: set filetype=mustache: */}}
{{/*
Expand the name of the chart.
*/}}
{{- define "argo-cd.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 "argo-cd.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 -}}
{{/*
Create chart name and version as used by the chart label.
*/}}
{{- define "argo-cd.chart" -}}
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" -}}
{{- end -}}