94 lines
3.7 KiB
YAML
Executable File
94 lines
3.7 KiB
YAML
Executable File
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: {{ include "bff-app-k8s.fullname" . }}
|
|
labels:
|
|
{{- include "bff-app-k8s.selectorLabels" . | nindent 4 }}
|
|
spec:
|
|
replicas: {{ .Values.replicaCount }}
|
|
selector:
|
|
matchLabels:
|
|
{{- include "bff-app-k8s.selectorLabels" . | nindent 6 }}
|
|
template:
|
|
metadata:
|
|
annotations:
|
|
{{- toYaml .Values.podAnnotations | nindent 8 }}
|
|
labels:
|
|
{{- include "bff-app-k8s.selectorLabels" . | nindent 8 }}
|
|
{{- toYaml .Values.podLabels | nindent 8 }}
|
|
spec:
|
|
volumes:
|
|
- name: ca-cert
|
|
configMap:
|
|
name: auth-app-ca-cert
|
|
items:
|
|
- key: RootCA_{{ .Values.global.cert_alias }}.crt
|
|
path: RootCA_{{ .Values.global.cert_alias }}.crt
|
|
- name: cacerts-volume
|
|
emptyDir: {}
|
|
# initContainers:
|
|
# - name: import-ca
|
|
# image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
|
|
# env:
|
|
# - name: CERT_ALIAS
|
|
# value: {{ .Values.global.cert_alias | quote }}
|
|
# volumeMounts:
|
|
# - name: ca-cert
|
|
# mountPath: /app/resources
|
|
# - name: cacerts-volume
|
|
# mountPath: /tmp/cacerts
|
|
# command:
|
|
# - sh
|
|
# - -c
|
|
# - |
|
|
# cp /usr/lib/jvm/java-21-amazon-corretto/lib/security/cacerts /tmp/cacerts/cacerts &&
|
|
# keytool -import -trustcacerts -storepass changeit -noprompt \
|
|
# -alias gemcert \
|
|
# -file /app/resources/RootCA_${CERT_ALIAS}.crt \
|
|
# -keystore /tmp/cacerts/cacerts
|
|
containers:
|
|
- name: bff-app
|
|
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
|
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
|
ports:
|
|
- containerPort: {{ .Values.service.targetPort }}
|
|
{{- if .Values.service.hostPort }}
|
|
hostPort: {{ .Values.service.hostPort }}
|
|
{{- end }}
|
|
protocol: TCP
|
|
env:
|
|
- name: GRPC_CLIENT_AUTH_URL
|
|
value: {{ .Values.env.services.auth | quote }}
|
|
- name: GRPC_CLIENT_CHAT_URL
|
|
value: {{ .Values.env.services.chat | quote }}
|
|
- name: GRPC_CLIENT_CONFIG_URL
|
|
value: {{ .Values.env.services.user | quote }}
|
|
- name: GRPC_CLIENT_DEEPLINK_URL
|
|
value: {{ .Values.env.services.deeplink | quote }}
|
|
- name: GRPC_CLIENT_GEM_CALL_URL
|
|
value: {{ .Values.env.services.gemCall | quote }}
|
|
- name: GRPC_CLIENT_MESSAGE_URL
|
|
value: {{ .Values.env.services.message | quote }}
|
|
- name: GRPC_CLIENT_NOTIFICATIONS_URL
|
|
value: {{ .Values.env.services.notification | quote }}
|
|
- name: GRPC_CLIENT_REACTION_URL
|
|
value: {{ .Values.env.services.message | quote }}
|
|
- name: GRPC_CLIENT_REALTIME_URL
|
|
value: {{ .Values.env.services.realtime | quote }}
|
|
- name: GRPC_CLIENT_SEARCH_URL
|
|
value: {{ .Values.env.services.search | quote }}
|
|
- name: GRPC_CLIENT_STICKER_URL
|
|
value: {{ .Values.env.services.sticker | quote }}
|
|
- name: GRPC_CLIENT_UPLOAD_URL
|
|
value: {{ .Values.env.services.upload | quote }}
|
|
- name: GRPC_CLIENT_USER_URL
|
|
value: {{ .Values.env.services.user | quote }}
|
|
- name: GRPC_CLIENT_WORKSPACE_URL
|
|
value: {{ .Values.env.services.workspace | quote }}
|
|
resources:
|
|
{{- toYaml .Values.resources | nindent 12 }}
|
|
volumeMounts:
|
|
- name: cacerts-volume
|
|
mountPath: /usr/lib/jvm/java-21-amazon-corretto/lib/security/cacerts
|
|
subPath: cacerts
|