Merge "Fix CSIT for PMSH"
[integration/csit.git] / scripts / policy / docker-compose-all.yml
1 #
2 # ===========LICENSE_START====================================================
3 #  Copyright (C) 2020 AT&T Intellectual Property. All rights reserved.
4 # ============================================================================
5 # Licensed under the Apache License, Version 2.0 (the "License");
6 # you may not use this file except in compliance with the License.
7 # You may obtain a copy of the License at
8 #
9 #      http://www.apache.org/licenses/LICENSE-2.0
10 #
11 # Unless required by applicable law or agreed to in writing, software
12 # distributed under the License is distributed on an "AS IS" BASIS,
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 # See the License for the specific language governing permissions and
15 # limitations under the License.
16 # ============LICENSE_END=====================================================
17 #
18 version: '2'
19 services:
20    mariadb:
21       image: nexus3.onap.org:10001/mariadb:${POLICY_MARIADB_VER}
22       container_name: mariadb
23       hostname: mariadb
24       command: ['--lower-case-table-names=1', '--wait_timeout=28800']
25       env_file: config/db/db.conf
26       volumes:
27          - ./config/db:/docker-entrypoint-initdb.d:ro
28       expose:
29        - 3306
30    policy.api.simpledemo.onap.org:
31       image: nexus3.onap.org:10001/onap/policy-models-simulator:${POLICY_MODELS_VERSION}
32       container_name: policy.api.simpledemo.onap.org
33       hostname: policy.api.simpledemo.onap.org
34       volumes:
35        - ./config/sim-all:/opt/app/policy/simulators/etc/mounted:ro
36       expose:
37        - 6666
38        - 6668
39        - 6669
40        - 6670
41        - 3905
42    api:
43       image: nexus3.onap.org:10001/onap/policy-api:${POLICY_API_VERSION}
44       container_name: policy-api
45       depends_on:
46        - mariadb
47       hostname: policy-api
48       expose:
49        - 6969
50       volumes:
51        - ./wait_for_port.sh:/opt/app/policy/api/bin/wait_for_port.sh:ro
52       entrypoint: ./wait_for_port.sh
53       command: [
54         '-c', './policy-api.sh',
55         'mariadb', '3306'
56         ]
57    pap:
58       image: nexus3.onap.org:10001/onap/policy-pap:${POLICY_PAP_VERSION}
59       container_name: policy-pap
60       depends_on:
61        - mariadb
62        - policy.api.simpledemo.onap.org
63        - api
64       hostname: policy-pap
65       expose:
66        - 6969
67       volumes:
68        - ./config/pap/defaultConfig.json:/opt/app/policy/pap/etc/defaultConfig.json:ro
69        - ./wait_for_port.sh:/opt/app/policy/pap/bin/wait_for_port.sh:ro
70       entrypoint: ./wait_for_port.sh
71       command: [
72         '-c', './policy-pap.sh',
73         'mariadb', '3306',
74         'policy.api.simpledemo.onap.org', '3905',
75         'api', '6969'
76         ]
77    xacml-pdp:
78       image: nexus3.onap.org:10001/onap/policy-xacml-pdp:${POLICY_XACML_PDP_VERSION}
79       container_name: policy-xacml-pdp
80       depends_on:
81        - mariadb
82        - policy.api.simpledemo.onap.org
83        - pap
84       hostname: policy-xacml-pdp
85       expose:
86        - 6969
87       volumes:
88        - ./config/xacml-pdp/defaultConfig.json:/opt/app/policy/pdpx/etc/defaultConfig.json:ro
89        - ./wait_for_port.sh:/opt/app/policy/pdpx/bin/wait_for_port.sh:ro
90       entrypoint: ./wait_for_port.sh
91       command: [
92         '-c', './policy-pdpx.sh',
93         'mariadb', '3306',
94         'policy.api.simpledemo.onap.org', '3905',
95         'pap', '6969'
96         ]
97    drools:
98       image: nexus3.onap.org:10001/onap/policy-drools:${POLICY_DROOLS_VERSION}
99       container_name: drools
100       depends_on:
101        - mariadb
102        - policy.api.simpledemo.onap.org
103        - pap
104       hostname: drools
105       expose:
106        - 6969
107        - 9696
108       volumes:
109        - ./config/drools/custom:/tmp/policy-install/config:ro
110        - ./wait_for_port.sh:/opt/app/policy/bin/wait_for_port.sh:ro
111       env_file:
112         - config/drools/env/base.conf
113       entrypoint: /opt/app/policy/bin/wait_for_port.sh
114       command: [
115         '-c', '/opt/app/policy/bin/pdpd-entrypoint.sh boot',
116         'mariadb', '3306',
117         'policy.api.simpledemo.onap.org', '3905'
118         ]
119    drools-apps:
120       image: nexus3.onap.org:10001/onap/policy-pdpd-cl:${POLICY_DROOLS_APPS_VERSION}
121       container_name: drools-apps
122       depends_on:
123        - mariadb
124        - policy.api.simpledemo.onap.org
125        - pap
126        - xacml-pdp
127       hostname: drools-apps
128       expose:
129        - 6969
130        - 9696
131       volumes:
132        - ./config/drools-apps/custom:/tmp/policy-install/config:ro
133        - ./wait_for_port.sh:/opt/app/policy/bin/wait_for_port.sh:ro
134       env_file:
135         - config/drools-apps/env/base.conf
136         - config/drools-apps/env/feature-healthcheck.conf
137         - config/drools-apps/env/feature-pooling-dmaap.conf
138       entrypoint: /opt/app/policy/bin/wait_for_port.sh
139       command: [
140         '-c', '/opt/app/policy/bin/pdpd-cl-entrypoint.sh boot',
141         'mariadb', '3306',
142         'policy.api.simpledemo.onap.org', '3905',
143         'pap', '6969',
144         'policy.api.simpledemo.onap.org', '6666',
145         'policy.api.simpledemo.onap.org', '6668',
146         'policy.api.simpledemo.onap.org', '6669',
147         'policy.api.simpledemo.onap.org', '6670'
148         ]
149    apex-pdp:
150       image: nexus3.onap.org:10001/onap/policy-apex-pdp:${POLICY_APEX_PDP_VERSION}
151       container_name: policy-apex-pdp
152       depends_on:
153        - mariadb
154        - policy.api.simpledemo.onap.org
155        - pap
156       hostname: policy-apex-pdp
157       expose:
158        - 6969
159        - 23324
160       volumes:
161        - ./config/apex-pdp/OnapPfConfig.json:/opt/app/policy/apex-pdp/etc/onappf/config/OnapPfConfig.json:ro
162        - ./wait_for_port.sh:/opt/app/policy/bin/wait_for_port.sh:ro
163       entrypoint: /opt/app/policy/bin/wait_for_port.sh
164       command: [
165         '-c', '/opt/app/policy/apex-pdp/bin/apexOnapPf.sh -c /opt/app/policy/apex-pdp/etc/onappf/config/OnapPfConfig.json',
166         'mariadb', '3306',
167         'policy.api.simpledemo.onap.org', '3905',
168         'pap', '6969'
169         ]
170    distribution:
171       image: nexus3.onap.org:10001/onap/policy-distribution:${POLICY_DISTRIBUTION_VERSION}
172       container_name: policy-distribution
173       depends_on:
174        - mariadb
175        - api
176        - pap
177        - apex-pdp
178       hostname: policy-distribution
179       volumes:
180        - ./config/distribution/defaultConfig.json:/opt/app/policy/distribution/etc/defaultConfig.json:ro
181        - ./policy-distribution/config/distribution/temp/:/opt/app/policy/distribution/etc/temp/:ro
182        - ./wait_for_port.sh:/opt/app/policy/bin/wait_for_port.sh:ro
183       entrypoint: /opt/app/policy/bin/wait_for_port.sh
184       command: [
185         '-c', './policy-dist.sh',
186         'mariadb', '3306',
187         'policy.api.simpledemo.onap.org', '3905',
188         'pap', '6969',
189         'apex-pdp', '6969'
190         ]