Skip to content

Commit

Permalink
[FAB-1370] Add orderer and peer binaries to testenv
Browse files Browse the repository at this point in the history
Change-Id: I0b940003c4c686aaa0dfef3406b8427bc7cf0022
Signed-off-by: Luis Sanchez <sanchezl@us.ibm.com>
  • Loading branch information
Luis Sanchez committed Jan 14, 2017
1 parent 9e8fb87 commit 2e4c239
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 4 deletions.
7 changes: 6 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,12 @@ build/image/peer/payload: build/docker/bin/peer \
build/genesis-sampleconfig.tar.bz2
build/image/orderer/payload: build/docker/bin/orderer \
orderer/orderer.yaml
build/image/testenv/payload: build/gotools.tar.bz2
build/image/testenv/payload: build/gotools.tar.bz2 \
build/docker/bin/orderer \
orderer/orderer.yaml \
build/docker/bin/peer \
peer/core.yaml \
build/msp-sampleconfig.tar.bz2
build/image/runtime/payload: build/docker/busybox

build/image/%/payload:
Expand Down
15 changes: 12 additions & 3 deletions bddtests/environments/orderer-n-kafka-n/orderer/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,17 @@
FROM hyperledger/fabric-orderer
FROM hyperledger/fabric-testenv
WORKDIR /opt/gopath/src/github.com/hyperledger/fabric/orderer
RUN apt-get update \
&& apt-get install -y zookeeper jq \
RUN DEBIAN_FRONTEND=noninteractive apt-get update \
&& DEBIAN_FRONTEND=noninteractive apt-get install -y zookeeper jq \
&& rm -rf /var/lib/apt/lists/*
ENV ORDERER_GENERAL_LEDGERTYPE=ram \
ORDERER_GENERAL_BATCHTIMEOUT=10s \
ORDERER_GENERAL_BATCHSIZE=10 \
ORDERER_GENERAL_MAXWINDOWSIZE=1000 \
ORDERER_GENERAL_LISTENADDRESS=0.0.0.0 \
ORDERER_GENERAL_LISTENPORT=7050 \
ORDERER_RAMLEDGER_HISTORY_SIZE=100 \
ORDERER_GENERAL_GENESISMETHOD=provisional
ENV ORDERER_GENERAL_ORDERERTYPE=kafka
ADD docker-entrypoint.sh /docker-entrypoint.sh
ENTRYPOINT ["/docker-entrypoint.sh"]
CMD ["orderer"]
22 changes: 22 additions & 0 deletions images/testenv/Dockerfile.in
Original file line number Diff line number Diff line change
@@ -1,3 +1,25 @@
FROM hyperledger/fabric-baseimage:_BASE_TAG_

# fabric configuration file locations
RUN mkdir -p /etc/hyperledger/fabric
ENV ORDERER_CFG_PATH /etc/hyperledger/fabric
ENV PEER_CFG_PATH /etc/hyperledger/fabric

# ledger db location
RUN mkdir -p /var/hyperledger/db

# install gotools
ADD payload/gotools.tar.bz2 /usr/local/bin/

# fabric configuration files
COPY payload/orderer.yaml $ORDERER_CFG_PATH
COPY payload/core.yaml $PEER_CFG_PATH
ADD payload/msp-sampleconfig.tar.bz2 $PEER_CFG_PATH


# fabric binaries
COPY payload/orderer /usr/local/bin
COPY payload/peer /usr/local/bin

# typically, this is mapped to a developer's dev environment
WORKDIR /opt/gopath/src/github.com/hyperledger/fabric

0 comments on commit 2e4c239

Please sign in to comment.