mirror of
https://github.com/bigchaindb/bigchaindb.git
synced 2024-10-13 13:34:05 +00:00
PVC for MDB in single BDB+MDB StatefulSet
This commit is contained in:
parent
b9e5bc84d9
commit
93d06b4e2a
@ -34,38 +34,43 @@ spec:
|
|||||||
name: bdb
|
name: bdb
|
||||||
labels:
|
labels:
|
||||||
app: bdb
|
app: bdb
|
||||||
annotations:
|
#annotations:
|
||||||
pod.beta.kubernetes.io/init-containers: '[
|
#pod.beta.kubernetes.io/init-containers: '[
|
||||||
{
|
# TODO mongodb user and group; id = 999
|
||||||
"name": "bdb-configure",
|
|
||||||
"image": "bigchaindb/bigchaindb:latest",
|
|
||||||
"command": ["bigchaindb", "-y", "configure", "mongodb"],
|
|
||||||
"volumeMounts": [
|
|
||||||
{
|
|
||||||
"name": "bigchaindb-data",
|
|
||||||
"mountPath": "/data"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
]'
|
|
||||||
spec:
|
spec:
|
||||||
terminationGracePeriodSeconds: 10
|
terminationGracePeriodSeconds: 10
|
||||||
containers:
|
containers:
|
||||||
- name: bdb-server
|
- name: bdb-server
|
||||||
image: bigchaindb/bigchaindb:latest
|
image: bigchaindb/bigchaindb:latest
|
||||||
args:
|
args:
|
||||||
- -c
|
|
||||||
- /data/.bigchaindb
|
|
||||||
- start
|
- start
|
||||||
|
env:
|
||||||
|
- name: BIGCHAINDB_KEYPAIR_PRIVATE
|
||||||
|
value: 3CjmRhu718gT1Wkba3LfdqX5pfYuBdaMPLd7ENUga5dm
|
||||||
|
- name: BIGCHAINDB_KEYPAIR_PUBLIC
|
||||||
|
value: EEWUAhsk94ZUHhVw7qx9oZiXYDAWc9cRz93eMrsTG4kZ
|
||||||
|
- name: BIGCHAINDB_KEYRING
|
||||||
|
value: ""
|
||||||
|
- name: BIGCHAINDB_DATABASE_BACKEND
|
||||||
|
value: mongodb
|
||||||
|
- name: BIGCHAINDB_DATABASE_HOST
|
||||||
|
value: localhost
|
||||||
|
- name: BIGCHAINDB_DATABASE_PORT
|
||||||
|
value: "27017"
|
||||||
|
- name: BIGCHAINDB_SERVER_BIND
|
||||||
|
value: "0.0.0.0:9984"
|
||||||
|
- name: BIGCHAINDB_DATABASE_REPLICASET
|
||||||
|
value: bigchain-rs
|
||||||
|
- name: BIGCHAINDB_DATABASE_NAME
|
||||||
|
value: bigchain
|
||||||
|
- name: BIGCHAINDB_BACKLOG_REASSIGN_DELAY
|
||||||
|
value: "120"
|
||||||
imagePullPolicy: IfNotPresent
|
imagePullPolicy: IfNotPresent
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 9984
|
- containerPort: 9984
|
||||||
hostPort: 9984
|
hostPort: 9984
|
||||||
name: bdb-port
|
name: bdb-port
|
||||||
protocol: TCP
|
protocol: TCP
|
||||||
volumeMounts:
|
|
||||||
- name: bigchaindb-data
|
|
||||||
mountPath: /data
|
|
||||||
resources:
|
resources:
|
||||||
limits:
|
limits:
|
||||||
cpu: 200m
|
cpu: 200m
|
||||||
@ -76,12 +81,6 @@ spec:
|
|||||||
port: bdb-port
|
port: bdb-port
|
||||||
initialDelaySeconds: 15
|
initialDelaySeconds: 15
|
||||||
timeoutSeconds: 10
|
timeoutSeconds: 10
|
||||||
# readinessProbe:
|
|
||||||
# httpGet:
|
|
||||||
# path: /
|
|
||||||
# port: bdb-port
|
|
||||||
# initialDelaySeconds: 15
|
|
||||||
# timeoutSeconds: 10
|
|
||||||
- name: mongodb
|
- name: mongodb
|
||||||
image: mongo:3.4.1
|
image: mongo:3.4.1
|
||||||
args:
|
args:
|
||||||
@ -91,7 +90,7 @@ spec:
|
|||||||
- containerPort: 27017
|
- containerPort: 27017
|
||||||
hostPort: 27017
|
hostPort: 27017
|
||||||
name: mdb-port
|
name: mdb-port
|
||||||
protocol: TCP
|
protocol: TCP
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- name: mdb-data
|
- name: mdb-data
|
||||||
mountPath: /data
|
mountPath: /data
|
||||||
@ -108,9 +107,6 @@ spec:
|
|||||||
timeoutSeconds: 1
|
timeoutSeconds: 1
|
||||||
restartPolicy: Always
|
restartPolicy: Always
|
||||||
volumes:
|
volumes:
|
||||||
- name: bigchaindb-data
|
|
||||||
hostPath:
|
|
||||||
path: /disk/bigchaindb-data
|
|
||||||
- name: mdb-data
|
- name: mdb-data
|
||||||
hostPath:
|
persistentVolumeClaim:
|
||||||
path: /disk/mdb-data
|
claimName: mongoclaim
|
||||||
|
@ -50,10 +50,10 @@ spec:
|
|||||||
value: ""
|
value: ""
|
||||||
- name: BIGCHAINDB_DATABASE_BACKEND
|
- name: BIGCHAINDB_DATABASE_BACKEND
|
||||||
value: rethinkdb
|
value: rethinkdb
|
||||||
- name: BIGCHAINDB_DATABASE_PORT
|
|
||||||
value: "28015"
|
|
||||||
- name: BIGCHAINDB_DATABASE_HOST
|
- name: BIGCHAINDB_DATABASE_HOST
|
||||||
value: localhost
|
value: localhost
|
||||||
|
- name: BIGCHAINDB_DATABASE_PORT
|
||||||
|
value: "28015"
|
||||||
- name: BIGCHAINDB_SERVER_BIND
|
- name: BIGCHAINDB_SERVER_BIND
|
||||||
value: "0.0.0.0:9984"
|
value: "0.0.0.0:9984"
|
||||||
imagePullPolicy: IfNotPresent
|
imagePullPolicy: IfNotPresent
|
||||||
|
Loading…
x
Reference in New Issue
Block a user