cherrypick/chart/templates/Deployment.yml

48 lines
1.4 KiB
YAML
Raw Normal View History

2022-05-15 16:39:23 +09:00
apiVersion: apps/v1
kind: Deployment
metadata:
2023-05-28 18:35:56 +09:00
name: {{ include "cherrypick.fullname" . }}
2022-05-15 16:39:23 +09:00
labels:
2023-05-28 18:35:56 +09:00
{{- include "cherrypick.labels" . | nindent 4 }}
2022-05-15 16:39:23 +09:00
spec:
selector:
matchLabels:
2023-05-28 18:35:56 +09:00
{{- include "cherrypick.selectorLabels" . | nindent 6 }}
2022-05-15 16:39:23 +09:00
replicas: 1
template:
metadata:
labels:
2023-05-28 18:35:56 +09:00
{{- include "cherrypick.selectorLabels" . | nindent 8 }}
2022-05-15 16:39:23 +09:00
spec:
containers:
2022-09-15 20:32:25 +09:00
- name: cherrypick
2022-05-15 22:22:06 +09:00
image: {{ .Values.image }}
env:
- name: NODE_ENV
value: {{ .Values.environment }}
2022-05-15 16:39:23 +09:00
volumeMounts:
2023-05-28 18:35:56 +09:00
- name: {{ include "cherrypick.fullname" . }}-configuration
2022-09-15 20:32:25 +09:00
mountPath: /cherrypick/.config
2022-05-15 16:39:23 +09:00
readOnly: true
ports:
- containerPort: 3000
- name: postgres
image: postgres:15-alpine
2022-05-15 16:39:23 +09:00
env:
- name: POSTGRES_USER
2022-09-15 20:32:25 +09:00
value: "example-cherrypick-user"
2022-05-15 16:39:23 +09:00
- name: POSTGRES_PASSWORD
2022-09-15 20:32:25 +09:00
value: "example-cherrypick-pass"
2022-05-15 16:39:23 +09:00
- name: POSTGRES_DB
2022-09-15 20:32:25 +09:00
value: "cherrypick"
2022-05-15 16:39:23 +09:00
ports:
- containerPort: 5432
- name: redis
image: redis:7-alpine
2022-05-15 16:39:23 +09:00
ports:
- containerPort: 6379
volumes:
2023-05-28 18:35:56 +09:00
- name: {{ include "cherrypick.fullname" . }}-configuration
2022-05-15 16:39:23 +09:00
configMap:
2023-05-28 18:35:56 +09:00
name: {{ include "cherrypick.fullname" . }}-configuration