Merge "Removing unnecessary mounts in APEX CSIT"
[integration/csit.git] / tests / dcaegen2 / prh-testcases / resources / docker-compose.yml
1 version: "2.2"
2 services:
3   prh:
4     image: nexus3.onap.org:10001/onap/org.onap.dcaegen2.services.prh.prh-app-server:latest
5     ports:
6       - "8100:8100"
7       - "8433:8433"
8     volumes:
9       - ./simulator/certs:/tmp/certs
10     environment:
11       - HOSTNAME=dcae-prh
12       - CONSUL_HOST                # not in use, but still required by SDK - should be removed later on
13       - CONFIG_BINDING_SERVICE
14       - CONFIG_BINDING_SERVICE_SERVICE_PORT
15     container_name: prh
16     depends_on:
17       cbs:
18         condition: service_healthy
19       dmaap-mr:
20         condition: service_started
21       aai:
22         condition: service_started
23
24   dmaap-mr:
25     build:
26       context: simulator
27       dockerfile: DMaaP_simulator
28     ports:
29       - "2222:2222"
30       - "2223:2223"
31       - "2224:2224"
32     container_name: dmaap_simulator
33
34   aai:
35     build:
36       context: simulator
37       dockerfile: AAI_simulator
38     ports:
39       - "3333:3333"
40       - "3334:3334"
41       - "3335:3335"
42     container_name: aai_simulator
43
44   consul:
45     image: consul:1.0.6
46     ports:
47       - "8500:8500"
48     command: ["agent", "-bootstrap", "-client=0.0.0.0", "-server", "-ui", "-config-dir=/consul/consul.d"]
49     volumes:
50       - ./consul.d/:/consul/consul.d
51     container_name: consul
52
53   consul-cfg:
54     image: consul:1.0.6
55     restart: on-failure
56     command: ["kv", "put", "-http-addr=http://consul:8500", "dcae-prh", '{
57                                               "logging.level.org.onap.dcaegen2.services.prh": "debug",
58                                               "logging.level.org.onap.dcaegen2.services.sdk": "debug",
59                                               "dmaap.dmaapConsumerConfiguration.dmaapUserName":"admin",
60                                               "dmaap.dmaapConsumerConfiguration.dmaapUserPassword":"admin",
61                                               "dmaap.dmaapConsumerConfiguration.dmaapContentType": "application/json",
62                                               "dmaap.dmaapConsumerConfiguration.consumerId": "c12",
63                                               "dmaap.dmaapConsumerConfiguration.consumerGroup": "OpenDCAE-c12",
64                                               "dmaap.dmaapConsumerConfiguration.timeoutMs": -1,
65                                               "dmaap.dmaapProducerConfiguration.dmaapUserName":"admin",
66                                               "dmaap.dmaapProducerConfiguration.dmaapUserPassword":"admin",
67                                               "dmaap.dmaapProducerConfiguration.dmaapContentType": "application/json",
68                                               "dmaap.dmaapUpdateProducerConfiguration.dmaapUserName": "admin",
69                                               "dmaap.dmaapUpdateProducerConfiguration.dmaapUserPassword": "admin",
70                                               "dmaap.dmaapUpdateProducerConfiguration.dmaapContentType": "application/json",
71                                               "aai.aaiClientConfiguration.pnfUrl":"https://aai:3334/aai/v12/network/pnfs/pnf",
72                                               "aai.aaiClientConfiguration.aaiUserName": "DCAE",
73                                               "aai.aaiClientConfiguration.aaiUserPassword": "DCAE",
74                                               "aai.aaiClientConfiguration.aaiIgnoreSslCertificateErrors": true,
75                                               "aai.aaiClientConfiguration.aaiServiceInstancePath":"/business/customers/customer/${customer}/service-subscriptions/service-subscription/${serviceType}/service-instances/service-instance/${serviceInstanceId}",
76                                               "aai.aaiClientConfiguration.aaiHeaders":{
77                                                 "X-FromAppId": "prh",
78                                                 "X-TransactionId": "9999",
79                                                 "Accept": "application/json",
80                                                 "Real-Time": "true",
81                                                 "Authorization": "Basic QUFJOkFBSQ=="
82                                               },
83                                               "security.trustStorePath":"/tmp/certs/truststore.jks",
84                                               "security.trustStorePasswordPath":"/tmp/certs/truststore.password",
85                                               "security.keyStorePath":"/tmp/certs/keystore.p12",
86                                               "security.keyStorePasswordPath":"/tmp/certs/keystore.password",
87                                               "security.enableAaiCertAuth":true,
88                                               "security.enableDmaapCertAuth":true,
89
90                                               "streams_publishes":{
91                                                 "pnf-update":{
92                                                   "type": "message_router",
93                                                   "dmaap_info":{
94                                                     "topic_url":"https://dmaap-mr:2223/events/unauthenticated.PNF_UPDATE"
95                                                   }
96                                                 },
97                                                 "pnf-ready":{
98                                                   "type": "message_router",
99                                                   "dmaap_info":{
100                                                     "topic_url":"https://dmaap-mr:2223/events/unauthenticated.PNF_READY"
101                                                   }
102                                                 }
103                                               },
104                                               "streams_subscribes":{
105                                                 "ves-reg-output":{
106                                                   "type": "message_router",
107                                                   "dmaap_info":{
108                                                     "topic_url":"https://dmaap-mr:2223/events/unauthenticated.VES_PNFREG_OUTPUT"
109                                                   }
110                                                 }
111                                               }
112                                             }'
113     ]
114     container_name: consul-cfg
115     depends_on:
116       - consul
117
118   consul-cfg-dcae-ves-collector:
119     image: consul:1.0.6
120     restart: on-failure
121     command: ["kv", "put", "-http-addr=http://consul:8500", "dcae-ves-collector",'{
122                                             "collector.dynamic.config.update.frequency": "5",
123                                             "event.transform.flag": "0",
124                                             "collector.schema.checkflag": "1",
125                                             "collector.dmaap.streamid": "fault=ves-fault|syslog=ves-syslog|heartbeat=ves-heartbeat|measurementsForVfScaling=ves-measurement|mobileFlow=ves-mobileflow|other=ves-other|stateChange=ves-statechange|thresholdCrossingAlert=ves-thresholdCrossingAlert|voiceQuality=ves-voicequality|sipSignaling=ves-sipsignaling|notification=ves-notification|pnfRegistration=ves-pnfRegistration",
126                                             "collector.service.port": "8080",
127                                             "collector.schema.file":"{
128                                               \"v1\":\"./etc/CommonEventFormat_27.2.json\",
129                                               \"v2\":\"./etc/CommonEventFormat_27.2.json\",
130                                               \"v3\":\"./etc/CommonEventFormat_27.2.json\",
131                                               \"v4\":\"./etc/CommonEventFormat_27.2.json\",
132                                               \"v5\":\"./etc/CommonEventFormat_28.4.1.json\",
133                                               \"v7\":\"./etc/CommonEventFormat_30.0.1.json\"
134                                             }",
135                                             "collector.keystore.passwordfile": "/opt/app/VESCollector/etc/passwordfile",
136                                             "collector.inputQueue.maxPending": "8096",
137                                             "streams_publishes":{
138                                               "ves-measurement": {
139                                                 "type": "message_router",
140                                                 "dmaap_info": {
141                                                   "topic_url": "http://dmaap-mr:2222/events/unauthenticated.VES_MEASUREMENT_OUTPUT/"
142                                                 }
143                                               },
144                                               "ves-fault": {
145                                                 "type": "message_router",
146                                                 "dmaap_info": {
147                                                   "topic_url": "http://dmaap-mr:2222/events/unauthenticated.SEC_FAULT_OUTPUT/"
148                                                 }
149                                               },
150                                               "ves-pnfRegistration": {
151                                                 "type": "message_router",
152                                                 "dmaap_info": {
153                                                   "topic_url": "http://dmaap-mr:2222/events/unauthenticated.VES_PNFREG_OUTPUT/"
154                                                 }
155                                               },
156                                               "ves-other": {
157                                                 "type": "message_router",
158                                                 "dmaap_info": {
159                                                   "topic_url": "http://dmaap-mr:2222/events/unauthenticated.SEC_OTHER_OUTPUT/"
160                                                 }
161                                               },
162                                               "ves-heartbeat": {
163                                                 "type": "message_router",
164                                                 "dmaap_info": {
165                                                   "topic_url": "http://dmaap-mr:2222/events/unauthenticated.SEC_HEARTBEAT_OUTPUT/"
166                                                 }
167                                               },
168                                               "ves-notification": {
169                                                 "type": "message_router",
170                                                 "dmaap_info": {
171                                                   "topic_url": "http://dmaap-mr:2222/events/unauthenticated.VES_NOTIFICATION_OUTPUT/"
172                                                   }
173                                               }
174                                             },
175                                             "collector.service.secure.port": "8443",
176                                             "header.authflag": "0",
177                                             "collector.keystore.file.location": "/opt/app/VESCollector/etc/keystore",
178                                             "collector.keystore.alias":
179                                             "dynamically generated",
180                                             "services_calls": [],
181                                             "header.authlist": "sample1,c2FtcGxlMQ=="
182                                             }']
183     container_name: consul-cfg-dcae-ves-collector
184     depends_on:
185       - consul
186
187
188   cbs:
189     image: nexus3.onap.org:10001/onap/org.onap.dcaegen2.platform.configbinding.app-app:2.2.4
190     ports:
191       - "10000:10000"
192     environment:
193       - CONSUL_HOST
194     depends_on:
195       - consul-cfg
196     healthcheck:
197       test: ["CMD", "curl", "-f", "http://localhost:10000/service_component_all/dcae-prh"]
198       interval: 3s
199       timeout: 2s
200       retries: 20
201     container_name: cbs