mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
Reorganize helm charts, add lifecycle hooks
- remove namespace, since it's best practice to use the cli to add it, @roschaefer points out - organize templates into directories - migrations should be ran after the backend has started... - should init really be ran every time??
This commit is contained in:
parent
aa799e6f6b
commit
a74abbb053
@ -1,5 +1,5 @@
|
|||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
appVersion: "0.1.0"
|
appVersion: "0.2.2"
|
||||||
description: A Helm chart for Human Connection
|
description: A Helm chart for Human Connection
|
||||||
name: human-connection
|
name: human-connection
|
||||||
version: 0.1.0
|
version: 0.1.0
|
||||||
|
|||||||
@ -2,7 +2,6 @@ apiVersion: apps/v1
|
|||||||
kind: Deployment
|
kind: Deployment
|
||||||
metadata:
|
metadata:
|
||||||
name: {{ .Release.Name }}-backend
|
name: {{ .Release.Name }}-backend
|
||||||
namespace: human-connection
|
|
||||||
spec:
|
spec:
|
||||||
replicas: 1
|
replicas: 1
|
||||||
minReadySeconds: 15
|
minReadySeconds: 15
|
||||||
@ -26,7 +25,11 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: backend
|
- name: backend
|
||||||
image: humanconnection/nitro-backend:latest
|
image: humanconnection/nitro-backend:latest
|
||||||
imagePullPolicy: {{ .Values.pullPolicy }}
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
|
lifecycle:
|
||||||
|
postStart:
|
||||||
|
exec:
|
||||||
|
command: ["/bin/sh", "-c", "{{ .Values.application.initializeCommand }}", "&&", "{{ .Values.application.migrationsCommand }}"]
|
||||||
envFrom:
|
envFrom:
|
||||||
- configMapRef:
|
- configMapRef:
|
||||||
name: {{ .Release.Name }}-configmap
|
name: {{ .Release.Name }}-configmap
|
||||||
@ -3,7 +3,6 @@ apiVersion: apps/v1
|
|||||||
kind: Deployment
|
kind: Deployment
|
||||||
metadata:
|
metadata:
|
||||||
name: {{ .Release.Name }}-mailserver
|
name: {{ .Release.Name }}-mailserver
|
||||||
namespace: human-connection
|
|
||||||
spec:
|
spec:
|
||||||
replicas: 1
|
replicas: 1
|
||||||
minReadySeconds: 15
|
minReadySeconds: 15
|
||||||
@ -20,7 +19,7 @@ spec:
|
|||||||
containers:
|
containers:
|
||||||
- name: mailserver
|
- name: mailserver
|
||||||
image: djfarrelly/maildev
|
image: djfarrelly/maildev
|
||||||
imagePullPolicy: {{ .Values.pullPolicy }}
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 80
|
- containerPort: 80
|
||||||
- containerPort: 25
|
- containerPort: 25
|
||||||
@ -2,7 +2,6 @@ apiVersion: apps/v1
|
|||||||
kind: Deployment
|
kind: Deployment
|
||||||
metadata:
|
metadata:
|
||||||
name: {{ .Release.Name }}-maintenance
|
name: {{ .Release.Name }}-maintenance
|
||||||
namespace: human-connection
|
|
||||||
spec:
|
spec:
|
||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
@ -2,7 +2,6 @@ apiVersion: apps/v1
|
|||||||
kind: Deployment
|
kind: Deployment
|
||||||
metadata:
|
metadata:
|
||||||
name: {{ .Release.Name }}-neo4j
|
name: {{ .Release.Name }}-neo4j
|
||||||
namespace: human-connection
|
|
||||||
spec:
|
spec:
|
||||||
replicas: 1
|
replicas: 1
|
||||||
strategy:
|
strategy:
|
||||||
@ -23,8 +22,8 @@ spec:
|
|||||||
spec:
|
spec:
|
||||||
containers:
|
containers:
|
||||||
- name: neo4j
|
- name: neo4j
|
||||||
image: humanconnection/neo4j:latest
|
image: humanconnection/neo4j:0.2.2
|
||||||
imagePullPolicy: {{ .Values.pullPolicy }}
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 7687
|
- containerPort: 7687
|
||||||
- containerPort: 7474
|
- containerPort: 7474
|
||||||
@ -36,12 +35,10 @@ spec:
|
|||||||
env:
|
env:
|
||||||
- name: NEO4J_dbms_security_procedures_unrestricted
|
- name: NEO4J_dbms_security_procedures_unrestricted
|
||||||
value: "algo.*,apoc.*"
|
value: "algo.*,apoc.*"
|
||||||
- name: SECURE_FILE_PERMISSIONS
|
|
||||||
value: "yes"
|
|
||||||
{{- range $key, $val := .Values.neo4jConfig }}
|
{{- range $key, $val := .Values.neo4jConfig }}
|
||||||
- name: NEO4J_{{ $key }}
|
- name: NEO4J_{{ $key }}
|
||||||
value: {{ $val | quote }}
|
value: {{ $val | quote }}
|
||||||
{{- end}}
|
{{- end }}
|
||||||
envFrom:
|
envFrom:
|
||||||
- configMapRef:
|
- configMapRef:
|
||||||
name: {{ .Release.Name }}-configmap
|
name: {{ .Release.Name }}-configmap
|
||||||
@ -2,7 +2,6 @@ apiVersion: apps/v1
|
|||||||
kind: Deployment
|
kind: Deployment
|
||||||
metadata:
|
metadata:
|
||||||
name: {{ .Release.Name }}-webapp
|
name: {{ .Release.Name }}-webapp
|
||||||
namespace: human-connection
|
|
||||||
spec:
|
spec:
|
||||||
replicas: 2
|
replicas: 2
|
||||||
minReadySeconds: 15
|
minReadySeconds: 15
|
||||||
@ -19,8 +18,8 @@ spec:
|
|||||||
spec:
|
spec:
|
||||||
containers:
|
containers:
|
||||||
- name: webapp
|
- name: webapp
|
||||||
image: humanconnection/nitro-web:latest
|
image: humanconnection/nitro-web:0.2.2
|
||||||
imagePullPolicy: {{ .Values.pullPolicy }}
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
envFrom:
|
envFrom:
|
||||||
- configMapRef:
|
- configMapRef:
|
||||||
name: {{ .Release.Name }}-configmap
|
name: {{ .Release.Name }}-configmap
|
||||||
@ -2,7 +2,6 @@ apiVersion: extensions/v1beta1
|
|||||||
kind: Ingress
|
kind: Ingress
|
||||||
metadata:
|
metadata:
|
||||||
name: {{ .Release.Name }}-ingress
|
name: {{ .Release.Name }}-ingress
|
||||||
namespace: human-connection
|
|
||||||
annotations:
|
annotations:
|
||||||
kubernetes.io/ingress.class: "nginx"
|
kubernetes.io/ingress.class: "nginx"
|
||||||
cert-manager.io/cluster-issuer: {{ .Values.letsencryptIssuer }}
|
cert-manager.io/cluster-issuer: {{ .Values.letsencryptIssuer }}
|
||||||
@ -2,7 +2,6 @@ apiVersion: v1
|
|||||||
kind: Service
|
kind: Service
|
||||||
metadata:
|
metadata:
|
||||||
name: {{ .Release.Name }}-backend
|
name: {{ .Release.Name }}-backend
|
||||||
namespace: human-connection
|
|
||||||
spec:
|
spec:
|
||||||
ports:
|
ports:
|
||||||
- name: graphql
|
- name: graphql
|
||||||
@ -2,7 +2,6 @@ apiVersion: v1
|
|||||||
kind: Service
|
kind: Service
|
||||||
metadata:
|
metadata:
|
||||||
name: {{ .Release.Name }}-neo4j
|
name: {{ .Release.Name }}-neo4j
|
||||||
namespace: human-connection
|
|
||||||
spec:
|
spec:
|
||||||
ports:
|
ports:
|
||||||
- name: bolt
|
- name: bolt
|
||||||
@ -2,7 +2,6 @@ apiVersion: v1
|
|||||||
kind: Service
|
kind: Service
|
||||||
metadata:
|
metadata:
|
||||||
name: {{ .Release.Name }}-webapp
|
name: {{ .Release.Name }}-webapp
|
||||||
namespace: human-connection
|
|
||||||
spec:
|
spec:
|
||||||
ports:
|
ports:
|
||||||
- name: {{ .Release.Name }}-webapp
|
- name: {{ .Release.Name }}-webapp
|
||||||
@ -1,24 +1,32 @@
|
|||||||
domain: develop.human-connection.org
|
domain: develop.human-connection.org
|
||||||
commit: 889a7cdd24dda04a139b2b77d626e984d6db6781
|
commit: 889a7cdd24dda04a139b2b77d626e984d6db6781
|
||||||
pullPolicy: Always
|
|
||||||
|
|
||||||
# configs
|
# configs
|
||||||
|
application:
|
||||||
|
initializeCommand: "yarn prod:migrate init"
|
||||||
|
migrationsCommand: "yarn prod:migrate up"
|
||||||
developmentMailserverDomain: "mailserver.human-connection.org"
|
developmentMailserverDomain: "mailserver.human-connection.org"
|
||||||
humanConnectionDomain: "develop.human-connection.org"
|
humanConnectionDomain: "develop.human-connection.org"
|
||||||
supportEmail: "devcom@human-connection.org"
|
image:
|
||||||
|
pullPolicy: Always
|
||||||
letsencryptIssuer: "letsencrypt-prod"
|
letsencryptIssuer: "letsencrypt-prod"
|
||||||
smtpHost: "mailserver.human-connection"
|
|
||||||
smtpPort: "25"
|
|
||||||
smtpUsername:
|
|
||||||
smtpPassword:
|
|
||||||
neo4jResourceRequestsMemory: "1G"
|
|
||||||
neo4jResourceLimitsMemory: "2G"
|
|
||||||
neo4jConfig:
|
neo4jConfig:
|
||||||
apoc_import_file_enabled: "true"
|
apoc_import_file_enabled: "true"
|
||||||
dbms_memory_pagecache_size: "490M"
|
dbms_memory_pagecache_size: "490M"
|
||||||
dbms_memory_heap_max__size: "500M"
|
dbms_memory_heap_max__size: "500M"
|
||||||
dbms_memory_heap_initial__size: "500M"
|
dbms_memory_heap_initial__size: "500M"
|
||||||
|
neo4jResourceLimitsMemory: "2G"
|
||||||
|
neo4jResourceRequestsMemory: "1G"
|
||||||
|
supportEmail: "devcom@human-connection.org"
|
||||||
|
smtpHost: "mailserver.human-connection"
|
||||||
|
smtpPort: "25"
|
||||||
|
smtpUsername:
|
||||||
|
smtpPassword:
|
||||||
|
volumes:
|
||||||
|
uploads:
|
||||||
|
storage: 5Gi
|
||||||
|
neo4jData:
|
||||||
|
storage: 8Gi
|
||||||
# secrets
|
# secrets
|
||||||
jwtSecret: "Yi8mJjdiNzhCRiZmdi9WZA=="
|
jwtSecret: "Yi8mJjdiNzhCRiZmdi9WZA=="
|
||||||
privateKeyPassphrase: "YTdkc2Y3OHNhZGc4N2FkODdzZmFnc2FkZzc4"
|
privateKeyPassphrase: "YTdkc2Y3OHNhZGc4N2FkODdzZmFnc2FkZzc4"
|
||||||
|
|||||||
@ -38,7 +38,7 @@ spec:
|
|||||||
name: human-connection
|
name: human-connection
|
||||||
image: humanconnection/nitro-backend:latest
|
image: humanconnection/nitro-backend:latest
|
||||||
imagePullPolicy: Always
|
imagePullPolicy: Always
|
||||||
name: nitro-backend
|
name: backend
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 4000
|
- containerPort: 4000
|
||||||
protocol: TCP
|
protocol: TCP
|
||||||
|
|||||||
@ -9,4 +9,4 @@
|
|||||||
- ReadWriteOnce
|
- ReadWriteOnce
|
||||||
resources:
|
resources:
|
||||||
requests:
|
requests:
|
||||||
storage: 25Gi
|
storage: 8Gi
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user