mirror of
https://github.com/bigchaindb/bigchaindb.git
synced 2024-10-13 13:34:05 +00:00
Deploy events API on k8s over on HTTP
This commit is contained in:
parent
6cb75960b0
commit
b8407d603a
@ -4,6 +4,7 @@ First Node or Bootstrap Node Setup
|
||||
This document is a work in progress and will evolve over time to include
|
||||
security, websocket and other settings.
|
||||
|
||||
|
||||
Step 1: Set Up the Cluster
|
||||
--------------------------
|
||||
|
||||
@ -421,8 +422,12 @@ Step 17. Verify that the Cluster is Correctly Set Up
|
||||
nslookup bdb-instance-0
|
||||
|
||||
dig +noall +answer _bdb-port._tcp.bdb-instance-0.default.svc.cluster.local SRV
|
||||
|
||||
dig +noall +answer _bdb-ws-port._tcp.bdb-instance-0.default.svc.cluster.local SRV
|
||||
|
||||
curl -X GET http://bdb-instance-0:9984
|
||||
|
||||
wsc ws://bdb-instance-0:9985/api/v1/streams/valid_tx
|
||||
|
||||
* Verify NGINX instance
|
||||
|
||||
@ -435,12 +440,16 @@ Step 17. Verify that the Cluster is Correctly Set Up
|
||||
curl -X GET http://ngx-instance-0:27017 # results in curl: (56) Recv failure: Connection reset by peer
|
||||
|
||||
dig +noall +answer _ngx-public-bdb-port._tcp.ngx-instance-0.default.svc.cluster.local SRV
|
||||
|
||||
dig +noall +answer _ngx-public-ws-port._tcp.ngx-instance-0.default.svc.cluster.local SRV
|
||||
|
||||
* If you have run the vanilla NGINX instance, run
|
||||
|
||||
.. code:: bash
|
||||
|
||||
curl -X GET http://ngx-instance-0:80
|
||||
|
||||
wsc ws://ngx-instance-0:81/api/v1/streams/valid_tx
|
||||
|
||||
* If you have the OpenResty NGINX + 3scale instance, run
|
||||
|
||||
|
@ -35,6 +35,10 @@ spec:
|
||||
value: bigchain
|
||||
- name: BIGCHAINDB_SERVER_BIND
|
||||
value: 0.0.0.0:9984
|
||||
- name: BIGCHAINDB_WSSERVER_HOST
|
||||
value: 0.0.0.0
|
||||
- name: BIGCHAINDB_WSSERVER_PORT
|
||||
value: "9985"
|
||||
- name: BIGCHAINDB_KEYPAIR_PUBLIC
|
||||
value: "<public key here>"
|
||||
- name: BIGCHAINDB_KEYPAIR_PRIVATE
|
||||
@ -54,7 +58,11 @@ spec:
|
||||
- containerPort: 9984
|
||||
hostPort: 9984
|
||||
name: bdb-port
|
||||
protocol: TCP
|
||||
protocol: TCP
|
||||
- containerPort: 9985
|
||||
hostPort: 9985
|
||||
name: bdb-ws-port
|
||||
protocol: TCP
|
||||
resources:
|
||||
limits:
|
||||
cpu: 200m
|
||||
|
@ -12,5 +12,8 @@ spec:
|
||||
- port: 9984
|
||||
targetPort: 9984
|
||||
name: bdb-port
|
||||
- port: 9985
|
||||
targetPort: 9985
|
||||
name: bdb-ws-port
|
||||
type: ClusterIP
|
||||
clusterIP: None
|
||||
|
@ -43,15 +43,23 @@ spec:
|
||||
configMapKeyRef:
|
||||
name: mongodb-whitelist
|
||||
key: allowed-hosts
|
||||
- name: BIGCHAINDB_WS_FRONTEND_PORT
|
||||
value: "81"
|
||||
- name: BIGCHAINDB_WS_BACKEND_PORT
|
||||
value: "9985"
|
||||
ports:
|
||||
- containerPort: 27017
|
||||
hostPort: 27017
|
||||
name: public-mdb-port
|
||||
protocol: TCP
|
||||
protocol: TCP
|
||||
- containerPort: 80
|
||||
hostPort: 80
|
||||
name: public-bdb-port
|
||||
protocol: TCP
|
||||
protocol: TCP
|
||||
- containerPort: 81
|
||||
hostPort: 81
|
||||
name: public-ws-port
|
||||
protocol: TCP
|
||||
resources:
|
||||
limits:
|
||||
cpu: 200m
|
||||
|
@ -21,4 +21,8 @@ spec:
|
||||
targetPort: 80
|
||||
name: ngx-public-bdb-port
|
||||
protocol: TCP
|
||||
- port: 81
|
||||
targetPort: 81
|
||||
name: ngx-public-ws-port
|
||||
protocol: TCP
|
||||
type: LoadBalancer
|
||||
|
@ -7,9 +7,10 @@ FROM alpine:3.5
|
||||
LABEL maintainer "dev@bigchaindb.com"
|
||||
WORKDIR /
|
||||
RUN apk add --no-cache --update curl bind-tools python3-dev g++ \
|
||||
libffi-dev make vim git \
|
||||
libffi-dev make vim git nodejs \
|
||||
&& pip3 install ipython \
|
||||
&& git clone https://github.com/bigchaindb/bigchaindb-driver \
|
||||
&& cd bigchaindb-driver \
|
||||
&& pip3 install -e .
|
||||
&& pip3 install -e . \
|
||||
&& npm install -g wsc
|
||||
ENTRYPOINT ["/bin/sh"]
|
||||
|
Loading…
x
Reference in New Issue
Block a user