2016-11-29 6 views
1

Bluemix Services에 car-lease-demo를 배포하려고하는데 swaggerApi에서 올바른 코드 경로를 찾을 수 없습니다. 나는 github repo from IBM를 사용했습니다하지만이 오류를 출력합니다REST-chaincodeID 경로를 통해 car-lease-demo를 배포 할 때 "chaincode 패키지 바이트를 가져 오는 중 오류가 발생했습니다"

{ 
    "jsonrpc": "2.0", 
    "error": { 
     "code": -32001, 
     "message": "Deployment failure", 
     "data": "Error when deploying chaincode: Error getting chaincode package bytes: Error getting code 'go get' failed with error: \"exit status 1\"\npackage github.com/IBM-Blockchain/car-lease-demo/Chaincode/vehicle_code: cannot find package \"github.com/IBM-Blockchain/car-lease-demo/Chaincode/vehicle_code\" in any of:\n\t/opt/go/src/github.com/IBM-Blockchain/car-lease-demo/Chaincode/vehicle_code (from $GOROOT)\n\t/opt/gopath/_usercode_/798513695/src/github.com/IBM-Blockchain/car-lease-demo/Chaincode/vehicle_code (from $GOPATH)\n\t/opt/gopath/src/github.com/IBM-Blockchain/car-lease-demo/Chaincode/vehicle_code\n" 
    }, 
    "id": 3 
} 

나는이 source를 발견하고, JSON 탭을 선택하지만, 처음에 언급되어있는 패키지가 작동하지 않습니다.

BMX에 car-lease-demo chaincode를 배포하기위한 chaincodeID의 올바른 경로는 무엇입니까?

go get <chaincode path>가 chaincode의 배포시 실패 오류 메시지에 말했듯이 나는 BMX의 v0.6

+0

[이 답변] (http://stackoverflow.com/a/40208148/1270789) 및 [이 답변] (http://stackoverflow.com/a/40646412/1270789) 유사한 문제에 대한 해결책을 제공합니다 . –

+0

이 답변을 보았습니다. 그러나 자동차 임대 계약 데모를위한 구체적인 경로가 있어야한다고 생각합니다. 또한 오류없이 "learn-chaincode"예제를 배포했으며 사용중인 BMX 버전이 내가 생각하는 오류에 대해 문제가되어서는 안됩니다. –

답변

1

을 사용하고 있습니다. 이는 배포 요청의 체인 코드 path이 잘못 되었기 때문입니다. 이 chaincode에 대한 올바른 chaincode 경로는 다음과 같습니다

을 :이 방식으로 웹에서 chaincode 배포를 시도하기 전에, 당신은 이동의 chaincode이 작업을 수행하여 웹을 통해 액세스 할 수있는 경우 확인할 수 있습니다 말했다

github.com/IBM-Blockchain/car-lease-demo/Chaincode/src/vehicle_code 

go get <public chaincode path> 
+0

답변 해 주셔서 감사합니다 :) 올바른 경로를 어디에서 찾았는지 또는 어떻게 알 수 있습니까? 나는이 [link] (http://go-search.org/view?id=github.com%2Fhyperledger%2Ffabric%2Fcore%2Fchaincode%2Fshim)에서 사용하고있는 경로를 발견했습니다. 목록 ... –

+0

코드는 github에 있습니다 ... 그래서 여기 그것을 발견 https://github.com/IBM-Blockchain/car-lease-demo/tree/master/Chaincode/src/vehicle_code. 방금 길을 시험해 보았습니다. – cjcroix