forked from olegabu/fabric-starter
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-composetemplate-peer.yaml
107 lines (98 loc) · 3.09 KB
/
docker-composetemplate-peer.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
#
# Copyright Altoros. All Rights Reserved.
#
version: '2'
services:
ca.ORG.DOMAIN:
container_name: ca.ORG.DOMAIN
image: hyperledger/fabric-ca:x86_64-1.0.0
environment:
- FABRIC_CA_HOME=/etc/hyperledger/fabric-ca-server
- FABRIC_CA_SERVER_CA_CERTFILE=/etc/hyperledger/fabric-ca-server-config/ca.ORG.DOMAIN-cert.pem
- FABRIC_CA_SERVER_CA_KEYFILE=/etc/hyperledger/fabric-ca-server-config/CA_PRIVATE_KEY
- FABRIC_CA_SERVER_TLS_ENABLED=true
- FABRIC_CA_SERVER_TLS_CERTFILE=/etc/hyperledger/fabric-ca-server-config/ca.ORG.DOMAIN-cert.pem
- FABRIC_CA_SERVER_TLS_KEYFILE=/etc/hyperledger/fabric-ca-server-config/CA_PRIVATE_KEY
# ports:
# - CA_PORT:7054
command: sh -c 'fabric-ca-server start -b admin:adminpw -d'
volumes:
- ../artifacts/crypto-config/peerOrganizations/ORG.DOMAIN/ca/:/etc/hyperledger/fabric-ca-server-config
- ../artifacts/fabric-ca-server-config-ORG.yaml:/etc/hyperledger/fabric-ca-server/fabric-ca-server-config.yaml
peer0.ORG.DOMAIN:
container_name: peer0.ORG.DOMAIN
extends:
file: base.yaml
service: peer-base
environment:
- CORE_PEER_ID=peer0.ORG.DOMAIN
- CORE_PEER_LOCALMSPID=ORGMSP
- CORE_PEER_ADDRESS=peer0.ORG.DOMAIN:7051
ports:
- PEER0_PORT:7051
# - PEER0_EVENT_PORT:7053
volumes:
- ../artifacts/crypto-config/peerOrganizations/ORG.DOMAIN/peers/peer0.ORG.DOMAIN/:/etc/hyperledger/crypto/peer
depends_on:
- ca.ORG.DOMAIN
PEER_EXTRA_HOSTS
peer1.ORG.DOMAIN:
container_name: peer1.ORG.DOMAIN
extends:
file: base.yaml
service: peer-base
environment:
- CORE_PEER_ID=peer1.ORG.DOMAIN
- CORE_PEER_LOCALMSPID=ORGMSP
- CORE_PEER_ADDRESS=peer1.ORG.DOMAIN:7051
ports:
- PEER1_PORT:7051
# - PEER1_EVENT_PORT:7053
volumes:
- ../artifacts/crypto-config/peerOrganizations/ORG.DOMAIN/peers/peer1.ORG.DOMAIN/:/etc/hyperledger/crypto/peer
depends_on:
- ca.ORG.DOMAIN
PEER_EXTRA_HOSTS
# api server
api.ORG.DOMAIN:
extends:
file: base.yaml
service: api-base
container_name: api.ORG.DOMAIN
ports:
- API_PORT:4000
environment:
- ORG=ORG
- PORT=4000
depends_on:
- peer0.ORG.DOMAIN
- peer1.ORG.DOMAIN
API_EXTRA_HOSTS
cli.DOMAIN:
container_name: cli.DOMAIN
extends:
file: base.yaml
service: cli-base
volumes:
- ../artifacts/crypto-config/ordererOrganizations/DOMAIN/orderers/orderer.DOMAIN/tls:/etc/hyperledger/crypto/orderer/tls
cli.ORG.DOMAIN:
container_name: cli.ORG.DOMAIN
extends:
service: cli.DOMAIN
environment:
- CORE_PEER_LOCALMSPID=ORGMSP
volumes:
- ../artifacts/crypto-config/peerOrganizations/ORG.DOMAIN/users/[email protected]:/etc/hyperledger/crypto/peer
depends_on:
- peer0.ORG.DOMAIN
- peer1.ORG.DOMAIN
- www.ORG.DOMAIN
CLI_EXTRA_HOSTS
# simple http server to disseminate certificates
www.ORG.DOMAIN:
extends:
file: base.yaml
service: www-base
container_name: www.ORG.DOMAIN
ports:
- WWW_PORT:80