먼저 환경 구축이 필요
docker
docker-compose
docker 설치 (hyperledger 구축 하기 위하여 여러개의 node 들이 필요한데 이를 docker 로 커버침)
docker-compose 설치 (docker 를 관리하기 위한 툴 ?)
이미 설치되어있는 시스템에서 재 설치 한것이라... 상황에따라 의존성 라이브러리가 설치됨에 따라 설치 로그가 길거나 시간이 더 걸릴 수 있습니다~~
그담에 필요한것은 hyperledger sample !
root@cj-VirtualBox:~# curl -sSL https://bit.ly/2ysbOFE | bash -s -- 2.3.2 1.5.1 Clone hyperledger/fabric-samples repo ===> Cloning hyperledger/fabric-samples repo 'fabric-samples'에 복제합니다... remote: Enumerating objects: 7743, done. remote: Counting objects: 100% (43/43), done. remote: Compressing objects: 100% (38/38), done. remote: Total 7743 (delta 14), reused 15 (delta 5), pack-reused 7700 오브젝트를 받는 중: 100% (7743/7743), 4.52 MiB | 4.44 MiB/s, 완료. 델타를 알아내는 중: 100% (4040/4040), 완료. fabric-samples v2.3.2 does not exist, defaulting to main. fabric-samples main branch is intended to work with recent versions of fabric. Pull Hyperledger Fabric binaries ===> Downloading version 2.3.2 platform specific fabric binaries ===> Downloading: https://github.com/hyperledger/fabric/releases/download/v2.3.2/hyperledger-fabric-linux-amd64-2.3.2.tar.gz % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 649 100 649 0 0 16641 0 --:--:-- --:--:-- --:--:-- 16641 100 73.5M 100 73.5M 0 0 25.5M 0 0:00:02 0:00:02 --:--:-- 28.0M ==> Done. ===> Downloading version 1.5.1 platform specific fabric-ca-client binary ===> Downloading: https://github.com/hyperledger/fabric-ca/releases/download/v1.5.1/hyperledger-fabric-ca-linux-amd64-1.5.1.tar.gz % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 652 100 652 0 0 15902 0 --:--:-- --:--:-- --:--:-- 15902 100 26.0M 100 26.0M 0 0 25.3M 0 0:00:01 0:00:01 --:--:-- 34.1M ==> Done. Pull Hyperledger Fabric docker images FABRIC_IMAGES: peer orderer ccenv tools baseos ===> Pulling fabric Images ====> hyperledger/fabric-peer:2.3.2 2.3.2: Pulling from hyperledger/fabric-peer Digest: sha256:f39281832923fc98695e3aebd998619e4ad3eec5acb861d2636a9be296b519d8 Status: Image is up to date for hyperledger/fabric-peer:2.3.2 docker.io/hyperledger/fabric-peer:2.3.2 ====> hyperledger/fabric-orderer:2.3.2 2.3.2: Pulling from hyperledger/fabric-orderer Digest: sha256:50f2c36e5d11a5ae9b266cf062299e538a0f5e95289b736f3c16108697a7bb13 Status: Image is up to date for hyperledger/fabric-orderer:2.3.2 docker.io/hyperledger/fabric-orderer:2.3.2 ====> hyperledger/fabric-ccenv:2.3.2 2.3.2: Pulling from hyperledger/fabric-ccenv Digest: sha256:08322a64b8d9789458d7f059d8c9e4a1fcdaf115ef04e5b5812aab5b34b5c264 Status: Image is up to date for hyperledger/fabric-ccenv:2.3.2 docker.io/hyperledger/fabric-ccenv:2.3.2 ====> hyperledger/fabric-tools:2.3.2 2.3.2: Pulling from hyperledger/fabric-tools Digest: sha256:00cbe11e72845724d50758c8ba4d3a8e674f0241490ca24251a8eb1dce96985a Status: Image is up to date for hyperledger/fabric-tools:2.3.2 docker.io/hyperledger/fabric-tools:2.3.2 ====> hyperledger/fabric-baseos:2.3.2 2.3.2: Pulling from hyperledger/fabric-baseos Digest: sha256:e3925478808ec334e3da7a5bf4ca5eb44b0b39e9134b5470b196a1c7d02f6ac7 Status: Image is up to date for hyperledger/fabric-baseos:2.3.2 docker.io/hyperledger/fabric-baseos:2.3.2 ===> Pulling fabric ca Image ====> hyperledger/fabric-ca:1.5.1 1.5.1: Pulling from hyperledger/fabric-ca Digest: sha256:c7f3422ec1d5fe5e5819563325f17a55d5e276cfed39ba51c5518c538de638a2 Status: Image is up to date for hyperledger/fabric-ca:1.5.1 docker.io/hyperledger/fabric-ca:1.5.1 ===> List out hyperledger docker images hyperledger/fabric-ca 1.5 c6803b1828da 2 weeks ago 70.8MB hyperledger/fabric-ca 1.5.1 c6803b1828da 2 weeks ago 70.8MB hyperledger/fabric-ca latest c6803b1828da 2 weeks ago 70.8MB hyperledger/fabric-tools 2.3 a206a1593b4c 4 months ago 448MB hyperledger/fabric-tools 2.3.2 a206a1593b4c 4 months ago 448MB hyperledger/fabric-tools latest a206a1593b4c 4 months ago 448MB hyperledger/fabric-peer 2.3 85c825d4769f 4 months ago 54.2MB hyperledger/fabric-peer 2.3.2 85c825d4769f 4 months ago 54.2MB hyperledger/fabric-peer latest 85c825d4769f 4 months ago 54.2MB hyperledger/fabric-orderer 2.3 7cad713cbfea 4 months ago 37.8MB hyperledger/fabric-orderer 2.3.2 7cad713cbfea 4 months ago 37.8MB hyperledger/fabric-orderer latest 7cad713cbfea 4 months ago 37.8MB hyperledger/fabric-ccenv 2.3 627c556b15ca 4 months ago 514MB hyperledger/fabric-ccenv 2.3.2 627c556b15ca 4 months ago 514MB hyperledger/fabric-ccenv latest 627c556b15ca 4 months ago 514MB hyperledger/fabric-baseos 2.3 e50ea411d694 4 months ago 6.86MB hyperledger/fabric-baseos 2.3.2 e50ea411d694 4 months ago 6.86MBhyperledger/fabric-baseos latest e50ea411d694 4 months ago 6.86MB root@cj-VirtualBox:~# |
curl -sSL https://bit.ly/2ysbOFE | bash -s -- 2.3.2 1.5.1 (현재 최신버젼-2021.09.02 - 1.5.0은 오류가나는듯?)
다운받은 컨텐츠 구성은 다음과 긑음
bin 안에 실행파일 - 주요 구동 프로그램
구동테스트
1) 네트워크 시작 network.sh up
2) 채널생성 network.sh createChannel -c mychannel
3) 체인코드배포 network.sh deployCC -ccn basic -ccp ../asset-transfer-basic/chaincode-javascript/ -ccl javascript
여기까지 문제없이 실행 된다면 기본 셋팅고 test-network 동작 환경은 구성 되었다!
트러블 슈팅)
- 케이스 요청
'Hyperledger Fabric' 카테고리의 다른 글
원장백업? (0) | 2021.09.02 |
---|---|
hyperledger Fable - test-network 시나리오 구동 (0) | 2021.09.02 |
Ubuntu 셋팅 설치 (0) | 2021.09.02 |
하이퍼레저패브릭 구동 테스트 (셋팅준비) (0) | 2021.09.01 |