This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. Run following command to create .bna file - | |
composer archive create -t dir -n . | |
2. Go to fabric-dev-servers folder and create PeerAdminCard | |
./createPeerAdminCard.sh | |
3. Go to fabric-dev-servers folder and start fabric | |
./startFabric.sh | |
4. Run command to check available card list |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
================== Local Single Node Setup ============= | |
1. cd eos | |
2. Build eos -> eosio_build.sh | |
3. Install eos -> eosio_install.sh | |
4. cd eos/build/programs/nodeos | |
5. ./nodeos -e -p eosio --plugin eosio::chain_api_plugin --plugin eosio::history_api_plugin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# This example sets up a network map using docker and registers a notary and a regular node that are run using java | |
# Make sure your node's node.conf has the following: | |
# | |
# compatibilityZoneURL="http://localhost:8080" | |
# devMode=false | |
# keyStorePassword="cordacadevpass" | |
# trustStorePassword="trustpass" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Base contract that all upgradeable contracts should use. | |
* | |
* Contracts implementing this interface are all called using delegatecall from | |
* a dispatcher. As a result, the _sizes and _dest variables are shared with the | |
* dispatcher contract, which allows the called contract to update these at will. | |
* | |
* _sizes is a map of function signatures to return value sizes. Due to EVM | |
* limitations, these need to be populated by the target contract, so the | |
* dispatcher knows how many bytes of data to return from called functions. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pragma solidity ^0.4.17; | |
import './MedicalRecord.sol'; | |
contract Hospital { | |
MedicalRecord public medicalRecord; | |
struct Patient { | |
bytes32 fullName; | |
bool access; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
contract Donation { | |
mapping (address => uint) user_amounts; | |
/* DOES THIS METHODS MODIFY user_amounts of the Relay contract ??? */ | |
function sendDonation(uint n) { | |
user_amounts[msg.sender] = user_amounts[msg.sender] + n | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
contract Database{ | |
mapping(uint => uint) public _data; | |
mapping(address => bool) _owners; | |
function Database(address[] owners){ //Called once at creation, pass in initial owners | |
for(uint i; i<owners.length; i++){ | |
_owners[owners[i]]=true; | |
} | |
} | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# to generate your dhparam.pem file, run in the terminal | |
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048 |