mirror of
https://gitlab.dit.htwk-leipzig.de/fsr-im/k8s/services/overleaf-cep.git
synced 2025-08-30 16:43:52 +02:00
Add MongoDB initialization script and update deployment configurations
This commit is contained in:
@@ -12,12 +12,18 @@ spec:
|
||||
labels:
|
||||
app: mongo
|
||||
spec:
|
||||
hostAliases:
|
||||
- ip: "127.0.0.1"
|
||||
hostnames:
|
||||
- "mongo"
|
||||
securityContext:
|
||||
runAsUser: 1001
|
||||
fsGroup: 0
|
||||
containers:
|
||||
- name: mongo
|
||||
image: {{ .Values.mongo.image }}
|
||||
command: ["mongod"]
|
||||
args: ["--replSet", "{{ .Values.mongo.replSet }}"]
|
||||
ports:
|
||||
- containerPort: {{ .Values.mongo.port }}
|
||||
env:
|
||||
@@ -36,6 +42,9 @@ spec:
|
||||
volumeMounts:
|
||||
- name: mongo-data
|
||||
mountPath: {{ .Values.mongo.volumeMounts.db }}
|
||||
- name: mongo-init
|
||||
mountPath: /docker-entrypoint-initdb.d/mongo-init.js
|
||||
subPath: mongo-init.js
|
||||
resources:
|
||||
requests:
|
||||
cpu: {{ .Values.resources.mongo.requests.cpu }}
|
||||
@@ -46,4 +55,7 @@ spec:
|
||||
volumes:
|
||||
- name: mongo-data
|
||||
persistentVolumeClaim:
|
||||
claimName: {{ .Values.persistence.mongoData }}
|
||||
claimName: {{ .Values.persistence.mongoData }}
|
||||
- name: mongo-init
|
||||
configMap:
|
||||
name: mongo-init-script
|
Reference in New Issue
Block a user