forked from olegabu/fabric-starter
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose-listener.yaml
51 lines (46 loc) · 1.57 KB
/
docker-compose-listener.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
#
# Copyright . All Rights Reserved.
#
version: '3.7'
services:
# block event listeners
dns.listener:
# build: listener
image: ${DOCKER_REGISTRY:-docker.io}/olegabu/fabric-starter-listener:${FABRIC_STARTER_VERSION:-latest}
restart: always
container_name: dns.listener.${ORG:-org1}.${DOMAIN:-example.com}
environment:
- ORG=${ORG:-org1}
- DOMAIN=${DOMAIN:-example.com}
- CRYPTO_CONFIG_DIR=/usr/src/app/crypto-config
- ENROLL_ID
- ENROLL_SECRET
- P=${PWD}
- HFC_LOGGING={"debug":"console","info":"console"}
- CHANNEL=common
- WORKER=./dns.js
volumes:
- ${WORK_DIR-/home/docker}/crypto-config/hosts_${ORG:-org1}:/etc/hosts
- ${WORK_DIR-/home/docker}/crypto-config:/usr/src/app/crypto-config
command: sh -c "sleep 60 && npm start"
# example of a custom listener that prints out blocks in debug log entries
#
# debug.listener:
# build: listener
# image: olegabu/fabric-starter-listener:${FABRIC_STARTER_VERSION:-latest}
# # restart: always
# container_name: debug.listener.${ORG:-org1}.${DOMAIN:-example.com}
# environment:
# - ORG=${ORG:-org1}
# - DOMAIN=${DOMAIN:-example.com}
# - CRYPTO_CONFIG_DIR=/usr/src/app/crypto-config
# - ENROLL_ID
# - ENROLL_SECRET
# - P=${PWD}
# - HFC_LOGGING={"debug":"console","info":"console"}
# - CHANNEL=common
# - WORKER=./debug.js
# volumes:
# - ${WORK_DIR-/home/docker}/hosts:/etc/hosts
# - ${WORK_DIR-/home/docker}/crypto-config:/usr/src/app/crypto-config
# command: sh -c "sleep 1 && npm start"