Add dev env for 1.0.0
parent
ce575e07de
commit
64f6a033fb
|
@ -62,21 +62,21 @@ start: # bootup the fabric network
|
||||||
|
|
||||||
init: # initialize the fabric network
|
init: # initialize the fabric network
|
||||||
@echo "Install and instantiate cc example02 on the fabric network"
|
@echo "Install and instantiate cc example02 on the fabric network"
|
||||||
docker exec -it fabric-cli bash ./scripts/initialize_all.sh
|
docker exec -it fabric-cli bash -c "cd /tmp; bash scripts/initialize_all.sh"
|
||||||
|
|
||||||
test_cc: # test chaincode
|
test_cc: # test chaincode
|
||||||
@echo "Invoke and query cc example02 on all peers"
|
@echo "Invoke and query cc example02 on all peers"
|
||||||
docker exec -it fabric-cli bash ./scripts/test_cc_all.sh
|
docker exec -it fabric-cli bash -c "cd /tmp; bash scripts/test_cc_all.sh"
|
||||||
|
|
||||||
test_peer0: # test single peer
|
test_peer0: # test single peer
|
||||||
@echo "Invoke and query cc example02 on single peer0"
|
@echo "Invoke and query cc example02 on single peer0"
|
||||||
docker exec -it fabric-cli bash ./scripts/test_cc_peer0.sh
|
docker exec -it fabric-cli bash -c "cd /tmp; bash scripts/test_cc_peer0.sh"
|
||||||
|
|
||||||
qscc: # test qscc quries
|
qscc: # test qscc quries
|
||||||
docker exec -it fabric-cli bash ./scripts/test_qscc.sh
|
docker exec -it fabric-cli bash -c "cd /tmp; bash scripts/test_qscc.sh"
|
||||||
|
|
||||||
lscc: # test lscc quries
|
lscc: # test lscc quries
|
||||||
docker exec -it fabric-cli bash ./scripts/test_lscc.sh
|
docker exec -it fabric-cli bash -c "cd /tmp; bash scripts/test_lscc.sh"
|
||||||
|
|
||||||
stop: # stop the fabric network
|
stop: # stop the fabric network
|
||||||
@echo "Stop the fabric network"
|
@echo "Stop the fabric network"
|
||||||
|
|
|
@ -54,12 +54,13 @@ services:
|
||||||
- CHANNEL_NAME:="businesschannel"
|
- CHANNEL_NAME:="businesschannel"
|
||||||
- ORDERER_CA=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/tlscacerts/tlsca.example.com-cert.pem
|
- ORDERER_CA=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/tlscacerts/tlsca.example.com-cert.pem
|
||||||
volumes:
|
volumes:
|
||||||
- ./e2e_cli/examples:/opt/gopath/src/github.com/hyperledger/fabric/examples
|
#- ./scripts:/opt/gopath/src/github.com/hyperledger/fabric/peer/scripts/
|
||||||
- ./e2e_cli/crypto-config:/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/
|
- ./scripts:/tmp/scripts
|
||||||
- ./scripts:/opt/gopath/src/github.com/hyperledger/fabric/peer/scripts/
|
- ./e2e_cli/channel-artifacts:/tmp/channel-artifacts
|
||||||
- ./e2e_cli/channel-artifacts:/opt/gopath/src/github.com/hyperledger/fabric/peer/channel-artifacts
|
|
||||||
- ./e2e_cli/configtx.yaml:/etc/hyperledger/fabric/configtx.yaml
|
- ./e2e_cli/configtx.yaml:/etc/hyperledger/fabric/configtx.yaml
|
||||||
- ./e2e_cli/crypto-config.yaml:/etc/hyperledger/fabric/crypto-config.yaml
|
- ./e2e_cli/crypto-config.yaml:/etc/hyperledger/fabric/crypto-config.yaml
|
||||||
|
- ./e2e_cli/crypto-config:/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto
|
||||||
|
- ./e2e_cli/examples:/opt/gopath/src/github.com/hyperledger/fabric/examples
|
||||||
working_dir: /opt/gopath/src/github.com/hyperledger/fabric/peer
|
working_dir: /opt/gopath/src/github.com/hyperledger/fabric/peer
|
||||||
command: bash -c 'while true; do sleep 20170504; done'
|
command: bash -c 'while true; do sleep 20170504; done'
|
||||||
|
|
||||||
|
|
|
@ -35,7 +35,7 @@ services:
|
||||||
#extends:
|
#extends:
|
||||||
# file: peer-base-dev.yaml
|
# file: peer-base-dev.yaml
|
||||||
# service: peer-base
|
# service: peer-base
|
||||||
image: hyperledger/fabric-tools
|
image: yeasy/hyperledger-fabric:1.0.0
|
||||||
container_name: fabric-cli
|
container_name: fabric-cli
|
||||||
hostname: fabric-cli
|
hostname: fabric-cli
|
||||||
tty: true
|
tty: true
|
||||||
|
@ -52,13 +52,15 @@ services:
|
||||||
- CHANNEL_NAME:="businesschannel"
|
- CHANNEL_NAME:="businesschannel"
|
||||||
- ORDERER_CA=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/tlscacerts/tlsca.example.com-cert.pem
|
- ORDERER_CA=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/tlscacerts/tlsca.example.com-cert.pem
|
||||||
volumes:
|
volumes:
|
||||||
- ./e2e_cli/examples:/opt/gopath/src/github.com/hyperledger/fabric/examples
|
#- $GOPATH/src/github.com/hyperledger/:/go/src/github.com/hyperledger/
|
||||||
- ./e2e_cli/crypto-config:/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/
|
- ./scripts:/tmp/scripts
|
||||||
- ./scripts:/opt/gopath/src/github.com/hyperledger/fabric/peer/scripts/
|
- ./e2e_cli/channel-artifacts:/tmp/channel-artifacts
|
||||||
- ./e2e_cli/channel-artifacts:/opt/gopath/src/github.com/hyperledger/fabric/peer/channel-artifacts
|
|
||||||
- ./e2e_cli/configtx.yaml:/etc/hyperledger/fabric/configtx.yaml
|
- ./e2e_cli/configtx.yaml:/etc/hyperledger/fabric/configtx.yaml
|
||||||
- ./e2e_cli/crypto-config.yaml:/etc/hyperledger/fabric/crypto-config.yaml
|
- ./e2e_cli/crypto-config.yaml:/etc/hyperledger/fabric/crypto-config.yaml
|
||||||
#- $GOPATH/src/github.com/hyperledger/:/go/src/github.com/hyperledger/
|
- ./e2e_cli/crypto-config:/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto
|
||||||
|
- ./e2e_cli/examples:/opt/gopath/src/github.com/hyperledger/fabric/examples
|
||||||
|
- $GOPATH/src/github.com/hyperledger/fabric:/opt/gopath/src/github.com/hyperledger/fabric
|
||||||
|
- /tmp/:/tmp/
|
||||||
working_dir: /opt/gopath/src/github.com/hyperledger/fabric/peer
|
working_dir: /opt/gopath/src/github.com/hyperledger/fabric/peer
|
||||||
command: bash -c 'while true; do sleep 20170504; done'
|
command: bash -c 'while true; do sleep 20170504; done'
|
||||||
|
|
||||||
|
@ -82,8 +84,8 @@ services:
|
||||||
- 7051:7051
|
- 7051:7051
|
||||||
- 7052:7052
|
- 7052:7052
|
||||||
- 7053:7053
|
- 7053:7053
|
||||||
#command: bash -c 'bash /tmp/peer_build.sh; peer node start'
|
command: bash -c 'bash /tmp/peer_build.sh; peer node start'
|
||||||
command: peer node start
|
#command: peer node start
|
||||||
|
|
||||||
#networks:
|
#networks:
|
||||||
# default:
|
# default:
|
||||||
|
|
|
@ -8,7 +8,7 @@ version: '2'
|
||||||
|
|
||||||
services:
|
services:
|
||||||
peer-base:
|
peer-base:
|
||||||
image: yeasy/hyperledger-fabric
|
image: yeasy/hyperledger-fabric:1.0.0
|
||||||
environment:
|
environment:
|
||||||
#- CORE_PEER_ID=peer0
|
#- CORE_PEER_ID=peer0
|
||||||
- CORE_PEER_ADDRESSAUTODETECT=false
|
- CORE_PEER_ADDRESSAUTODETECT=false
|
||||||
|
@ -35,7 +35,6 @@ services:
|
||||||
- "7059" # tlsCAA
|
- "7059" # tlsCAA
|
||||||
volumes: # docker.sock is mapped as the default CORE_VM_ENDPOINT
|
volumes: # docker.sock is mapped as the default CORE_VM_ENDPOINT
|
||||||
- /var/run/docker.sock:/var/run/docker.sock
|
- /var/run/docker.sock:/var/run/docker.sock
|
||||||
- $GOPATH/src/github.com/hyperledger/:/go/src/github.com/hyperledger/
|
|
||||||
#volumes:
|
#volumes:
|
||||||
# - /var/run/:/host/var/run/
|
# - /var/run/:/host/var/run/
|
||||||
command: bash -c 'bash /tmp/peer_build.sh; peer node start'
|
command: bash -c 'bash /tmp/peer_build.sh; peer node start'
|
||||||
|
|
|
@ -23,6 +23,7 @@ createChannel
|
||||||
echo_b "Having all peers join the channel..."
|
echo_b "Having all peers join the channel..."
|
||||||
joinChannel
|
joinChannel
|
||||||
|
|
||||||
|
|
||||||
## Set the anchor peers for each org in the channel
|
## Set the anchor peers for each org in the channel
|
||||||
echo_b "Updating anchor peers for org1..."
|
echo_b "Updating anchor peers for org1..."
|
||||||
updateAnchorPeers 0
|
updateAnchorPeers 0
|
||||||
|
|
|
@ -26,7 +26,7 @@ echo_b "LSCC testing"
|
||||||
#--tls "true" \
|
#--tls "true" \
|
||||||
#--cafile ${ORDERER_CA} \
|
#--cafile ${ORDERER_CA} \
|
||||||
|
|
||||||
echo_b "Get cc name"
|
echo_b "Get id"
|
||||||
peer chaincode query \
|
peer chaincode query \
|
||||||
-C "${CHANNEL_NAME}" \
|
-C "${CHANNEL_NAME}" \
|
||||||
-n lscc \
|
-n lscc \
|
||||||
|
|
Loading…
Reference in New Issue