mirror of
https://gitlab.dit.htwk-leipzig.de/htwk-software/htwkalender.git
synced 2026-01-18 20:42:26 +01:00
add k8s deployment, improved Dockerfiles and docker-compose.yaml files
This commit is contained in:
49
charts/templates/deployment-frontend.yaml
Normal file
49
charts/templates/deployment-frontend.yaml
Normal file
@@ -0,0 +1,49 @@
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: {{ include "htwkalender.name" . }}-frontend
|
||||
namespace: {{ .Release.Namespace }}
|
||||
labels:
|
||||
{{- include "htwkalender.labels" . | nindent 4 }}
|
||||
component: frontend
|
||||
{{- with .Values.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 4 }}
|
||||
{{- end }}
|
||||
spec:
|
||||
replicas: {{ .Values.frontend.replicas }}
|
||||
selector:
|
||||
matchLabels:
|
||||
{{- include "htwkalender.selectorLabels" . | nindent 6 }}
|
||||
template:
|
||||
metadata:
|
||||
{{- with .Values.annotations }}
|
||||
annotations:
|
||||
{{- toYaml . | nindent 8 }}
|
||||
{{- end }}
|
||||
labels:
|
||||
{{- include "htwkalender.labels" . | nindent 8 }}
|
||||
component: frontend
|
||||
spec:
|
||||
containers:
|
||||
- name: {{ .Chart.Name }}-frontend
|
||||
image: "{{ .Values.frontend.image.name }}"
|
||||
imagePullPolicy: {{ .Values.frontend.image.pullPolicy }}
|
||||
ports:
|
||||
- name: frontend
|
||||
containerPort: {{ .Values.frontend.service.targetPort }}
|
||||
protocol: TCP
|
||||
volumeMounts:
|
||||
{{- if .Values.production }}
|
||||
- name: configmap-google
|
||||
mountPath: /{{ .Values.frontend.googleSiteVerification }}.html
|
||||
subPath: {{ .Values.frontend.googleSiteVerification }}.html
|
||||
readOnly: true
|
||||
{{- end }}
|
||||
{{- if .Values.production }}
|
||||
volumes:
|
||||
- name: configmap-google
|
||||
configMap:
|
||||
name: configmap-google
|
||||
{{- end }}
|
||||
|
||||
Reference in New Issue
Block a user