mirror of
https://github.com/bigchaindb/bigchaindb.git
synced 2024-10-13 13:34:05 +00:00

* Combining configs * Combining the persistent volume claims into a single file. * Combining the storage classes into a single file. * Updating documentation * Multiple changes * Support for ConfigMap * Custom MongoDB container for BigchainDB * Update documentation to run a single node on k8s * Additional documentation * Documentation to add a node to an existing BigchainDB cluster * Commit on rolling upgrades * Fixing minor documentation mistakes * Documentation updates as per @ttmc's comments * Block formatting error * Change in ConfigMap yaml config
58 lines
1.2 KiB
YAML
58 lines
1.2 KiB
YAML
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: mongodb
|
|
labels:
|
|
name: mongodb
|
|
spec:
|
|
ports:
|
|
- port: 27017
|
|
targetPort: 27017
|
|
clusterIP: None
|
|
selector:
|
|
role: mongodb
|
|
---
|
|
apiVersion: apps/v1beta1
|
|
kind: StatefulSet
|
|
metadata:
|
|
name: mongodb
|
|
spec:
|
|
serviceName: mongodb
|
|
replicas: 3
|
|
template:
|
|
metadata:
|
|
labels:
|
|
role: mongodb
|
|
environment: staging
|
|
spec:
|
|
terminationGracePeriodSeconds: 10
|
|
containers:
|
|
- name: mongo
|
|
image: mongo:3.4.1
|
|
command:
|
|
- mongod
|
|
- "--replSet"
|
|
- bigchain-rs
|
|
#- "--smallfiles"
|
|
#- "--noprealloc"
|
|
ports:
|
|
- containerPort: 27017
|
|
volumeMounts:
|
|
- name: mongo-persistent-storage
|
|
mountPath: /data/db
|
|
- name: mongo-sidecar
|
|
image: cvallance/mongo-k8s-sidecar
|
|
env:
|
|
- name: MONGO_SIDECAR_POD_LABELS
|
|
value: "role=mongo,environment=staging"
|
|
volumeClaimTemplates:
|
|
- metadata:
|
|
name: mongo-persistent-storage
|
|
annotations:
|
|
volume.beta.kubernetes.io/storage-class: "fast"
|
|
spec:
|
|
accessModes: [ "ReadWriteOnce" ]
|
|
resources:
|
|
requests:
|
|
storage: 100Gi
|