-
Notifications
You must be signed in to change notification settings - Fork 18
/
Copy pathdocker-compose.yaml
executable file
·190 lines (178 loc) · 4.36 KB
/
docker-compose.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
version: '2'
services:
insurance-ca:
container_name: insurance-ca
extends:
file: ./ca-base.yaml
service: ca-base
image: insurance-ca
ports:
- 7054:7054
shop-ca:
container_name: shop-ca
extends:
file: ./ca-base.yaml
service: ca-base
image: shop-ca
ports:
- 8054:7054
repairshop-ca:
container_name: repairshop-ca
extends:
file: ./ca-base.yaml
service: ca-base
image: repairshop-ca
ports:
- 9054:7054
police-ca:
container_name: police-ca
extends:
file: ./ca-base.yaml
service: ca-base
image: police-ca
ports:
- 10054:7054
orderer0:
container_name: orderer0
image: orderer
environment:
- ORDERER_GENERAL_LOGLEVEL=debug
- ORDERER_GENERAL_LISTENADDRESS=0.0.0.0
- ORDERER_GENERAL_GENESISMETHOD=file
- ORDERER_GENERAL_GENESISFILE=/orderer/crypto/genesis.block
- ORDERER_GENERAL_LOCALMSPID=OrdererMSP
- ORDERER_GENERAL_LOCALMSPDIR=/orderer/crypto/msp
- ORDERER_GENERAL_TLS_ENABLED=true
- ORDERER_GENERAL_TLS_PRIVATEKEY=/orderer/crypto/tls/server.key
- ORDERER_GENERAL_TLS_CERTIFICATE=/orderer/crypto/tls/server.crt
- ORDERER_GENERAL_TLS_ROOTCAS=[/orderer/crypto/tls/ca.crt]
working_dir: /orderer
command: orderer
ports:
- 7050:7050
insurance-peer:
container_name: insurance-peer
extends:
file: ./peer-base.yaml
service: peer-base
image: insurance-peer
environment:
- CORE_PEER_ID=insurance-peer
- CORE_PEER_ADDRESS=insurance-peer:7051
- CORE_PEER_GOSSIP_EXTERNALENDPOINT=insurance-peer:7051
- CORE_PEER_LOCALMSPID=InsuranceOrgMSP
ports:
- 7051:7051
- 7053:7053
depends_on:
- orderer0
shop-peer:
container_name: shop-peer
extends:
file: ./peer-base.yaml
service: peer-base
image: shop-peer
environment:
- CORE_PEER_ID=shop-peer
- CORE_PEER_ADDRESS=shop-peer:7051
- CORE_PEER_GOSSIP_EXTERNALENDPOINT=shop-peer:7051
- CORE_PEER_LOCALMSPID=ShopOrgMSP
ports:
- 8051:7051
- 8053:7053
depends_on:
- orderer0
- insurance-peer
repairshop-peer:
container_name: repairshop-peer
extends:
file: ./peer-base.yaml
service: peer-base
image: repairshop-peer
environment:
- CORE_PEER_ID=repairshop-peer
- CORE_PEER_ADDRESS=repairshop-peer:7051
- CORE_PEER_GOSSIP_EXTERNALENDPOINT=repairshop-peer:7051
- CORE_PEER_LOCALMSPID=RepairShopOrgMSP
ports:
- 9051:7051
- 9053:7053
depends_on:
- orderer0
- insurance-peer
- shop-peer
police-peer:
container_name: police-peer
extends:
file: ./peer-base.yaml
service: peer-base
image: police-peer
environment:
- CORE_PEER_ID=police-peer
- CORE_PEER_ADDRESS=police-peer:7051
- CORE_PEER_GOSSIP_EXTERNALENDPOINT=police-peer:7051
- CORE_PEER_LOCALMSPID=PoliceOrgMSP
ports:
- 10051:7051
- 10053:7053
depends_on:
- orderer0
- insurance-peer
- shop-peer
- repairshop-peer
web:
container_name: web
image: web
environment:
- PORT=3000
- DOCKER_SOCKET_PATH=/host/var/run/docker.sock
- DOCKER_CCENV_IMAGE=hyperledger/fabric-ccenv:latest
ports:
- 3000:3000
volumes:
- /var/run/:/host/var/run/
depends_on:
- orderer0
- insurance-ca
- insurance-peer
- shop-ca
- shop-peer
- repairshop-ca
- repairshop-peer
db2-fabric:
container_name: db2-fabric
hostname: db2server_
image: db2-fabric
env_file: ./db2-fabric/.db2-container.env
privileged: true
restart: always
ports:
- 50000:50000
- 55000:55000
volumes:
- ./db2-fabric/.db2-fabric:/database
- ./db2-fabric/build:/build
- ./db2-fabric/db2-container:/db2-container
- ./db2-fabric/samples:/samples
depends_on:
- orderer0
- insurance-ca
- insurance-peer
- shop-ca
- shop-peer
- repairshop-ca
- repairshop-peer
zeppelin:
container_name: zeppelin-notebook
image: zeppelin-notebook
ports:
- 8080:8080
volumes:
- ./zeppelin-notebook/notebook:/opt/zeppelin/notebook
environment:
DB2_FABRIC_JDBC_URL: "jdbc:db2://db2-fabric:50000/testdb"
DB2_FABRIC_DB2_DRIVER: "com.ibm.db2.jcc.DB2Driver"
DB2_FABRIC_DB2_USER: "db2inst1"
DB2_FABRIC_DB2_PASS: "password"
depends_on:
- db2-fabric