move files around, create new api/frontend yaml
This commit is contained in:
parent
7882179087
commit
98a5f67444
|
@ -0,0 +1,9 @@
|
||||||
|
{{- define "vikunja.api.hardcodedValues" -}}
|
||||||
|
{{ end }}
|
||||||
|
|
||||||
|
{{ if .Values.api.enabled }}
|
||||||
|
{{- $ctx := deepCopy . -}}
|
||||||
|
{{- $_ := get .Values "api" | mergeOverwrite $ctx.Values -}}
|
||||||
|
{{- $_ = include "vikunja.api.hardcodedValues" . | fromYaml | merge $ctx.Values -}}
|
||||||
|
{{- include "bjw-s.common.loader.all" $ctx }}
|
||||||
|
{{ end }}
|
|
@ -0,0 +1,9 @@
|
||||||
|
{{- define "vikunja.frontend.hardcodedValues" -}}
|
||||||
|
{{ end }}
|
||||||
|
|
||||||
|
{{ if .Values.frontend.enabled }}
|
||||||
|
{{- $ctx := deepCopy . -}}
|
||||||
|
{{- $_ := get .Values "frontend" | mergeOverwrite $ctx.Values -}}
|
||||||
|
{{- $_ = include "vikunja.frontend.hardcodedValues" . | fromYaml | merge $ctx.Values -}}
|
||||||
|
{{- include "bjw-s.common.loader.all" $ctx }}
|
||||||
|
{{ end }}
|
|
@ -1,107 +0,0 @@
|
||||||
apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: {{ include "vikunja.frontendFullname" . }}
|
|
||||||
labels:
|
|
||||||
{{- include "vikunja.labels" . | nindent 4 }}
|
|
||||||
spec:
|
|
||||||
{{- if not .Values.frontend.autoscaling.enabled }}
|
|
||||||
replicas: {{ .Values.frontend.replicaCount }}
|
|
||||||
{{- end }}
|
|
||||||
{{- with .Values.frontend.extraDeploymentSpec }}
|
|
||||||
{{- toYaml . | nindent 2 }}
|
|
||||||
{{- end }}
|
|
||||||
selector:
|
|
||||||
matchLabels:
|
|
||||||
{{- include "vikunja.frontendSelectorLabels" . | nindent 6 }}
|
|
||||||
template:
|
|
||||||
metadata:
|
|
||||||
{{- with .Values.frontend.podAnnotations }}
|
|
||||||
annotations:
|
|
||||||
{{- toYaml . | nindent 8 }}
|
|
||||||
{{- end }}
|
|
||||||
labels:
|
|
||||||
{{- include "vikunja.frontendSelectorLabels" . | nindent 8 }}
|
|
||||||
spec:
|
|
||||||
{{- with .Values.frontend.imagePullSecrets }}
|
|
||||||
imagePullSecrets:
|
|
||||||
{{- toYaml . | nindent 8 }}
|
|
||||||
{{- end }}
|
|
||||||
serviceAccountName: {{ include "vikunja.serviceAccountName" . }}
|
|
||||||
{{- with .Values.frontend.podSecurityContext }}
|
|
||||||
securityContext:
|
|
||||||
{{- toYaml . | nindent 8 }}
|
|
||||||
{{- end }}
|
|
||||||
{{- with .Values.frontend.initContainers }}
|
|
||||||
initContainers:
|
|
||||||
{{- toYaml . | nindent 8 }}
|
|
||||||
{{- end }}
|
|
||||||
containers:
|
|
||||||
{{- with .Values.frontend.sidecarContainers }}
|
|
||||||
{{- toYaml . | nindent 8 }}
|
|
||||||
{{- end }}
|
|
||||||
- name: frontend
|
|
||||||
{{- with .Values.frontend.securityContext }}
|
|
||||||
securityContext:
|
|
||||||
{{- toYaml . | nindent 10 }}
|
|
||||||
{{- end }}
|
|
||||||
{{- $image := required ".image.repository is not set" .Values.frontend.image.repository }}
|
|
||||||
{{- $tag := default .Chart.AppVersion .Values.frontend.image.tag | toString }}
|
|
||||||
image: {{ printf "%s:%s" $image $tag | quote }}
|
|
||||||
imagePullPolicy: {{ .Values.frontend.image.pullPolicy }}
|
|
||||||
ports:
|
|
||||||
- name: http
|
|
||||||
containerPort: 8080
|
|
||||||
protocol: TCP
|
|
||||||
env:
|
|
||||||
- name: VIKUNJA_API_URL
|
|
||||||
value: {{ quote .Values.frontend.apiUrl }}
|
|
||||||
- name: VIKUNJA_HTTP_PORT
|
|
||||||
value: "8080"
|
|
||||||
{{- with .Values.frontend.env }}
|
|
||||||
{{- toYaml . | nindent 8 }}
|
|
||||||
{{- end }}
|
|
||||||
{{- with .Values.frontend.envFrom }}
|
|
||||||
envFrom:
|
|
||||||
{{- toYaml . | nindent 8 }}
|
|
||||||
{{- end }}
|
|
||||||
{{- with .Values.frontend.livenessProbe }}
|
|
||||||
livenessProbe:
|
|
||||||
{{- toYaml . | nindent 10 }}
|
|
||||||
{{- end }}
|
|
||||||
{{- with .Values.frontend.readinessProbe }}
|
|
||||||
readinessProbe:
|
|
||||||
{{- toYaml . | nindent 10 }}
|
|
||||||
{{- end }}
|
|
||||||
{{- with .Values.frontend.startupProbe }}
|
|
||||||
startupProbe:
|
|
||||||
{{- toYaml . | nindent 10 }}
|
|
||||||
{{- end }}
|
|
||||||
{{- with .Values.frontend.resources }}
|
|
||||||
resources:
|
|
||||||
{{- toYaml . | nindent 10 }}
|
|
||||||
{{- end }}
|
|
||||||
volumeMounts:
|
|
||||||
- name: tmp
|
|
||||||
mountPath: /tmp
|
|
||||||
{{- with .Values.frontend.extraVolumeMounts }}
|
|
||||||
{{- toYaml . | nindent 8 }}
|
|
||||||
{{- end }}
|
|
||||||
volumes:
|
|
||||||
- name: tmp
|
|
||||||
emptyDir: {}
|
|
||||||
{{- with .Values.frontend.extraVolumes }}
|
|
||||||
{{- toYaml . | nindent 6 }}
|
|
||||||
{{- end }}
|
|
||||||
{{- with .Values.frontend.nodeSelector }}
|
|
||||||
nodeSelector:
|
|
||||||
{{- toYaml . | nindent 8 }}
|
|
||||||
{{- end }}
|
|
||||||
{{- with .Values.frontend.affinity }}
|
|
||||||
affinity:
|
|
||||||
{{- toYaml . | nindent 8 }}
|
|
||||||
{{- end }}
|
|
||||||
{{- with .Values.frontend.tolerations }}
|
|
||||||
tolerations:
|
|
||||||
{{- toYaml . | nindent 8 }}
|
|
||||||
{{- end }}
|
|
|
@ -0,0 +1,58 @@
|
||||||
|
{{- define "vikunja.frontend.hardcodedValues" -}}
|
||||||
|
global:
|
||||||
|
nameOverride: frontend
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ include "vikunja.frontendFullname" . }}
|
||||||
|
labels:
|
||||||
|
{{- include "vikunja.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
{{- if not .Values.frontend.autoscaling.enabled }}
|
||||||
|
replicas: {{ .Values.frontend.replicaCount }}
|
||||||
|
{{- end }}
|
||||||
|
{{- with .Values.frontend.extraDeploymentSpec }}
|
||||||
|
{{- toYaml . | nindent 2 }}
|
||||||
|
{{- end }}
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "vikunja.frontendSelectorLabels" . | nindent 6 }}
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
{{- with .Values.frontend.podAnnotations }}
|
||||||
|
annotations:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
labels:
|
||||||
|
{{- include "vikunja.frontendSelectorLabels" . | nindent 8 }}
|
||||||
|
spec:
|
||||||
|
{{- with .Values.frontend.imagePullSecrets }}
|
||||||
|
imagePullSecrets:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
serviceAccountName: {{ include "vikunja.serviceAccountName" . }}
|
||||||
|
{{- with .Values.frontend.podSecurityContext }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
containers:
|
||||||
|
- name: frontend
|
||||||
|
ports:
|
||||||
|
- name: http
|
||||||
|
containerPort: 8080
|
||||||
|
protocol: TCP
|
||||||
|
env:
|
||||||
|
- name: VIKUNJA_API_URL
|
||||||
|
value: {{ quote .Values.frontend.apiUrl }}
|
||||||
|
- name: VIKUNJA_HTTP_PORT
|
||||||
|
value: "8080"
|
||||||
|
volumeMounts:
|
||||||
|
- name: tmp
|
||||||
|
mountPath: /tmp
|
||||||
|
|
||||||
|
volumes:
|
||||||
|
- name: tmp
|
||||||
|
emptyDir: {}
|
||||||
|
|
|
@ -1,5 +0,0 @@
|
||||||
{{- range .Values.raw }}
|
|
||||||
{{- $manifest := include "vikunja.labels" $ | fromYaml | dict "labels" | dict "metadata" | mergeOverwrite . }}
|
|
||||||
{{- toYaml $manifest }}
|
|
||||||
---
|
|
||||||
{{- end }}
|
|
|
@ -1,9 +0,0 @@
|
||||||
apiVersion: v1
|
|
||||||
kind: Secret
|
|
||||||
metadata:
|
|
||||||
name: {{ include "vikunja.fullname" . }}
|
|
||||||
labels:
|
|
||||||
{{- include "vikunja.labels" . | nindent 4 }}
|
|
||||||
type: Opaque
|
|
||||||
data:
|
|
||||||
api-config.yaml: {{ toYaml .Values.api.config | b64enc }}
|
|
|
@ -1,15 +0,0 @@
|
||||||
{{- if .Values.serviceAccount.create -}}
|
|
||||||
apiVersion: v1
|
|
||||||
kind: ServiceAccount
|
|
||||||
metadata:
|
|
||||||
name: {{ include "vikunja.serviceAccountName" . }}
|
|
||||||
labels:
|
|
||||||
{{- include "vikunja.labels" . | nindent 4 }}
|
|
||||||
{{- with .Values.serviceAccount.labels }}
|
|
||||||
{{- toYaml . | nindent 4 }}
|
|
||||||
{{- end }}
|
|
||||||
{{- with .Values.serviceAccount.annotations }}
|
|
||||||
annotations:
|
|
||||||
{{- toYaml . | nindent 4 }}
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
Loading…
Reference in New Issue