Add conf file for MongoDB
Change-Id: If6635557d4b0f65188da0d7450ad37630b811996
This commit is contained in:
parent
34dd0bc5bd
commit
5f74107cde
@ -15,7 +15,7 @@ apiVersion: v1
|
|||||||
appVersion: v3.4.9
|
appVersion: v3.4.9
|
||||||
description: OpenStack-Helm MongoDB
|
description: OpenStack-Helm MongoDB
|
||||||
name: mongodb
|
name: mongodb
|
||||||
version: 0.1.4
|
version: 0.1.5
|
||||||
home: https://www.mongodb.com
|
home: https://www.mongodb.com
|
||||||
sources:
|
sources:
|
||||||
- https://github.com/mongodb/mongo
|
- https://github.com/mongodb/mongo
|
||||||
|
@ -16,7 +16,7 @@ limitations under the License.
|
|||||||
|
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
mongod --auth &
|
mongod --config /etc/mongodb.conf --auth &
|
||||||
|
|
||||||
t=0
|
t=0
|
||||||
until mongo --eval "db.adminCommand('ping')"; do
|
until mongo --eval "db.adminCommand('ping')"; do
|
||||||
|
26
mongodb/templates/configmap-etc.yaml
Normal file
26
mongodb/templates/configmap-etc.yaml
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
{{/*
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/}}
|
||||||
|
|
||||||
|
{{- if .Values.manifests.configmap_etc }}
|
||||||
|
{{- $envAll := . }}
|
||||||
|
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Secret
|
||||||
|
metadata:
|
||||||
|
name: mongodb-etc
|
||||||
|
type: Opaque
|
||||||
|
data:
|
||||||
|
mongodb.conf: {{ tuple "secrets/_mongodb.cnf.tpl" . | include "helm-toolkit.utils.template" | b64enc }}
|
||||||
|
{{- end }}
|
18
mongodb/templates/secrets/_mongodb.cnf.tpl
Normal file
18
mongodb/templates/secrets/_mongodb.cnf.tpl
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
{{/*
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/}}
|
||||||
|
|
||||||
|
bind_ip = {{ .Values.endpoints.mongodb.bind_ip}}
|
||||||
|
port = {{ .Values.endpoints.mongodb.port.mongodb.default}}
|
||||||
|
# Where to store the data.
|
||||||
|
dbpath=/var/lib/mongodb
|
@ -110,6 +110,10 @@ spec:
|
|||||||
mountPath: /tmp/setup_admin_user.sh
|
mountPath: /tmp/setup_admin_user.sh
|
||||||
subPath: setup_admin_user.sh
|
subPath: setup_admin_user.sh
|
||||||
readOnly: true
|
readOnly: true
|
||||||
|
- name: mongodb-etc
|
||||||
|
mountPath: /etc/mongodb.conf
|
||||||
|
subPath: mongodb.conf
|
||||||
|
readOnly: true
|
||||||
- name: mongodb-data
|
- name: mongodb-data
|
||||||
mountPath: /data/db
|
mountPath: /data/db
|
||||||
volumes:
|
volumes:
|
||||||
@ -119,6 +123,10 @@ spec:
|
|||||||
configMap:
|
configMap:
|
||||||
name: mongodb-bin
|
name: mongodb-bin
|
||||||
defaultMode: 0555
|
defaultMode: 0555
|
||||||
|
- name: mongodb-etc
|
||||||
|
secret:
|
||||||
|
secretName: mongodb-etc
|
||||||
|
defaultMode: 0444
|
||||||
{{- if not .Values.volume.enabled }}
|
{{- if not .Values.volume.enabled }}
|
||||||
- name: mongodb-data
|
- name: mongodb-data
|
||||||
hostPath:
|
hostPath:
|
||||||
|
@ -118,6 +118,7 @@ endpoints:
|
|||||||
default: null
|
default: null
|
||||||
path: null
|
path: null
|
||||||
scheme: mongodb
|
scheme: mongodb
|
||||||
|
bind_ip: 0.0.0.0
|
||||||
port:
|
port:
|
||||||
mongodb:
|
mongodb:
|
||||||
default: 27017
|
default: 27017
|
||||||
@ -141,6 +142,7 @@ dependencies:
|
|||||||
|
|
||||||
manifests:
|
manifests:
|
||||||
configmap_bin: true
|
configmap_bin: true
|
||||||
|
configmap_etc: true
|
||||||
job_image_repo_sync: true
|
job_image_repo_sync: true
|
||||||
secret_db_root_creds: true
|
secret_db_root_creds: true
|
||||||
secret_registry: true
|
secret_registry: true
|
||||||
|
@ -5,4 +5,5 @@ mongodb:
|
|||||||
- 0.1.2 Use full image ref for docker official images
|
- 0.1.2 Use full image ref for docker official images
|
||||||
- 0.1.3 Update htk requirements
|
- 0.1.3 Update htk requirements
|
||||||
- 0.1.4 Added OCI registry authentication
|
- 0.1.4 Added OCI registry authentication
|
||||||
|
- 0.1.5 Add conf file for MongoDB
|
||||||
...
|
...
|
||||||
|
Loading…
Reference in New Issue
Block a user