fabric-samples/chaincode-docker-devmode/script.sh
Nick Gaski ba777f3bcb [FAB-4371] - Chaincode Dev Mode
Adds a docker environment for running peer in dev mode
pre-baked crypto and orderer/channel artifacts
README still needs an updated curl command to bundle
these scripts.
simplified some of the paths
add sacc from write your first chaincode
remove binary

Change-Id: Ic1537987c819f0350ae6dbf740fd00e1571045e5
Signed-off-by: Nick Gaski <ngaski@us.ibm.com>
Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>
2017-06-23 13:00:49 -04:00

26 lines
1,019 B
Bash
Executable file

#!/bin/bash
# Copyright London Stock Exchange Group All Rights Reserved.
#
# SPDX-License-Identifier: Apache-2.0
set -e
# This script expedites the chaincode development process by automating the
# requisite channel create/join commands
# We use a pre-generated orderer.block and channel transaction artifact (myc.tx),
# both of which are created using the configtxgen tool
# first we create the channel against the specified configuration in myc.tx
# this call returns a channel configuration block - myc.block - to the CLI container
peer channel create -c myc -f myc.tx -o orderer:7050
# now we will join the channel and start the chain with myc.block serving as the
# channel's first block (i.e. the genesis block)
peer channel join -b myc.block
# Now the user can proceed to build and start chaincode in one terminal
# And leverage the CLI container to issue install instantiate invoke query commands in another
#we should have bailed if above commands failed.
#we are here, so they worked
sleep 600000
exit 0