update link to upper-constraints.txt
[dmaap/buscontroller.git] / docs / installation.rst
1 .. This work is licensed under a Creative Commons Attribution 4.0 International License.
2 .. http://creativecommons.org/licenses/by/4.0
3
4 Installation
5 ============
6
7 Bus Controller is developed using Postgresql.  An embedded Jetty server is used to create the REST service.
8 The service is packaged as a Docker container image.
9 Helm charts for Bus Controller are part of the overall dmaap chart set.
10
11 Steps for OOM Deployment
12 ------------------------
13
14 1) Clone the oom repo
15 2) cd oom/kubernetes
16 3) (optionally, customize the buscontroller configuration - see below)
17 4) make dmaap
18 5) helm install dmaap --name=dmaap --namespace=mr
19
20
21 Customizing the Bus Controller configuration
22 --------------------------------------------
23
24 The Bus Controller is highly configurable, but by default has settings that should work for a standard ONAP oom deployment.
25 However, if some customization is desired, there are places to change behavior:
26
27 1) The --namespace argument of the helm install step is also referenced to compose the topic namespace used.  i.e. the value is appended to org.onap.dmaap.   Since Message Router uses org.onap.dmaap.mr by default, we also use --namespace=mr.  But this can be changed to a value that matches a different deployment of MR.
28 2) oom/kubernetes/dmaap/charts/dmaap-bus-controller/values.yaml  contains the set of tags used within the charts.  These can be modified if necessary.
29 3) oom/kubernetes/dmaap/charts/dmaap-bus-controller/resources/config/buscontroller.env contains some environment settings for the container.  These can be modified.  For example, to indicate that AAF integration should be enabled, set USE_AAF=true in this file.
30 4) oom/kubernetes/dmaap/charts/dmaap-bus-controller/resources/config/dmaapbc.properties  contains many properties which can be modified.  For example, if a different Postgresql instance needed to be used, the value could be specified here.
31
32
33 Steps for local development and test
34 ------------------------------------
35 On Intel dev machine, in terminal (> indicates prompt) :
36 1) Build buscontroller images
37
38     > git clone https://gerrit.onap.org/r/dmaap/buscontroller
39         - anonymous http, can't push changes
40
41     > cd buscontroller
42
43     > mvn clean install -P docker
44
45         - builds dmaap-bc and dbc-client images
46
47 2) Run tests
48
49     > cd dmaap-bc/src/main/resources/
50
51     > cp docker-databus-controller.conf /var/tmp/
52
53         - set docker preferences/file sharing to access /var/tmp
54
55     - edit docker-compose.yml
56
57         - remove "nexus3.onap.org:10001/" from dmaap-bc:image: and dbc-client:image: to use local images
58
59     > docker-compose up -d
60     - create sample.txt file (as above)(content of file not important)
61
62     > curl http://localhost:30241/webapi/bridge
63
64 On Arm:
65 1) Build buscontroller images
66
67     > git clone https://gerrit.onap.org/r/dmaap/buscontroller
68         - anonymous http, can't push changes
69
70     > cd buscontroller
71
72     > mvn clean install -P docker  -Ddocker.pull.registry=docker.io
73         - ensure we pull Arm version of base image
74
75 2) Run tests
76
77     > cd dmaap-bc/src/main/resources/
78
79     > cp docker-databus-controller.conf /var/tmp/
80         - set docker preferences/file sharing to access /var/tmp
81
82     - edit docker-compose.yml
83         - remove "nexus3.onap.org:10001/" from dmaap-bc:image: and dbc-client:image: to
84             use local images
85         - replace 'crunchydata/crunchy-postgres:centos7-10.4-2.0.0' with
86             multi-platform 'postgres:9.6-alpine' normative image
87
88     > docker-compose up -d
89     - create sample.txt file (as above)(content of file not important)
90
91     > curl http://localhost:30241/webapi/bridge
92