Skip to content

Instantly share code, notes, and snippets.

View jorgedison's full-sized avatar
🏠
Working from home

Jorge Rodriguez Flores jorgedison

🏠
Working from home
View GitHub Profile
FOR %i IN (*.bak) DO "C:\Program Files\7-Zip\7z.exe" a "%~ni.7z" "%i"

enter image description here

Prerequisitos

- SO Ubuntu 18.04
- Docker 18.x 
- docker-compose 1.24.x
- NodeJs 8.11.x
- Go 1.11.x

Instalacion Docker

version: '2'
networks:
basic:
services:
orderer.midominio.com:
extends:
file: base/docker-compose-base.yaml
version: '2'
services:
peer-base:
image: hyperledger/fabric-peer
environment:
- CORE_VM_ENDPOINT=unix:///host/var/run/docker.sock
# the following setting starts chaincode containers on the same
# bridge network as the peers
# https://docs.docker.com/compose/networking/
# ---CHANGED---
version: '2'
services:
# ---CHANGED--- The orderer name is taken from the name generated by the "cryptogen" certs – it indicates the orderer orgs one and only orderer
orderer.dominio.com:
# ---CHANGED--- The container name is a copy of the orderer name
container_name: orderer.dominio.com
image: hyperledger/fabric-orderer
environment:
################################################################################
# Section: Organizations
################################################################################
Organizations:
- &OrdererOrg
Name: OrdererOrg
ID: OrdererMSP
MSPDir: crypto-config/ordererOrganizations/dominio.com/msp
OrdererOrgs:
- Name: Orderer
Domain: dominio.com
Specs:
- Hostname: orderer
PeerOrgs:
- Name: Org1
Domain: org1.dominio.com
EnableNodeOUs: true
Template:

enter image description here

Prerequisitos

- SO Ubuntu 18.04
- NodeJs 8.11.x
- PostgreSQL 10.x
- Jq 1.5.x
- Red Blockchain Hyperledger Fabric iniciada

Instalacion NodeJs

@jorgedison
jorgedison / test-nodejs.sh
Last active December 14, 2019 14:46
Chaincode nodejs
# Creacion de chaincode nodejs
#Ruta: ~/hyperledger/fabric/curso-fabric/chaincode
mkdir notasnodejs
cd notasnodejs
npm init
npm install --save fabric-contract-api
npm install --save fabric-shim
#Tomar como referencia
#package.json -> https://raw.githubusercontent.com/jorgedison/Prueba-Hyperledger-Fabric/master/chaincode/notasnodejs/package.json
### Unable to locate package `docker-ce` on a 64bit ubuntu
#### Ubuntu 18.10 (Cosmic)
sudo apt install apt-transport-https ca-certificates curl software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu bionic test"
#### Ubuntu 18.04 (bionic)