Blockfreight™ the blockchain of global freight
Package: go-blockfreight - Blockfreight™ v0.3.0
Description: go-blockfreight is the reference full node implementation and cli-tool for Blockfreight™ the blockchain of global freight.
A network for the free trade of physical goods so transformative it is part of the most advanced project in global shipping today.
go-blockfreight is a powerful, reliable, efficient and handy Go app for communicating with the Blockfreight™ blockchain.
Golang runtime and build environment
Go version 1.8+ or above.
Quick command line test:
$ go version
Validate you have Go installed and have defined
$GOPATH/bin in your
$PATH. For full instructions see golang.org site.
Glide version 0.12.3+ or above.
To manage all dependencies for go-bftx, it is necessary to have Glide installed.
$ glide -v
To install go-bftx, you can do it through:
$ go get github.com/blockfreight/go-bftx
Then, you need to update all dependencies by Glide. First go to go-bftx and update them:
$ cd $GOPATH/src/github.com/blockfreight/go-bftx $ glide install $ glide update
Install BFT-Node through
$ cd $GOPATH/src/github.com/blockfreight/go-bftx/cmd/bftnode $ go install
BFT-Node on OSX
Install BFT-Node through
$ cd $GOPATH/src/github.com/blockfreight/go-bftx/cmd/bftnode $ go build $ ./bftnode
Then, you can execute
bftnode. That app will start a server that is going to wait for requests from the
In other terminal, install BFTX through
$ cd $GOPATH/src/github.com/blockfreight/go-bftx/cmd/bftx $ go install
BFTX on OSX
In other terminal, install BFTX through
$ cd $GOPATH/src/github.com/blockfreight/go-bftx/cmd/bftx $ go build
After that step, you can execute
bftx. If you need some extra information, just add
$ bftx help
To start using go-blockfreight, you can check the JSON example file (bf_tx_example.json) localted on
/blockfreight/files/ or put your own JSON file verifying the proper structure against the JSON example file.
After that step, you can read the menu of bftx.
If you’d like to leave feedback, please open an issue on GitHub.
Blockfreight™ Project Layout
Blockfreight™ application code follows this convention:
├──.gitignore ├──.travis.yml ├──glide.lock ├──glide.yaml ├──LICENSE ├──Makefile ├──README.md ├──api ├──assets ├──bin ├──build │ ├──ci │ └──package │ └──version ├──cmd │ ├──bftnode │ └──bftx ├──config ├──deploy ├──docs ├──examples ├──githooks ├──init ├──lib │ ├──app │ │ ├──bf_tx │ │ ├──bft │ │ └──validator │ └──pkg │ ├──common │ ├──crytpo │ └──leveldb ├──pkg │ └──blockfreight ├──plugins ├──scripts ├──test ├──third_party ├──tools ├──vendor │ ├──github.com │ ├──golang.org │ └──google.golang.org └──web ├──app ├──static └──template
Blockfreight™ Application Code
OpenAPI/Swagger specs, JSON schema files, protocol definition files.
Other assets to go along with our repository.
Packaging and Continous Integration.
Put our cloud (AMI), container (Docker), OS (deb, rpm, pkg) package configurations and scripts in the
Put our CI (travis, circle, drone) configurations and scripts in the
Application and binary files required.
Main application code.
The directory name for each application matches the name of the executable we want to have (e.g.,
Don't put a lot of code in the application directory unless we think that code can be imported and used in other projects. If this is the case then the code should live in the
It's common to have a small main function that imports and invokes the code from the
Configuration file templates or default configs.
consule-template template files here.
IaaS, PaaS, system and container orchestration deployment configurations and templates (docker-compose, kubernetes/helm, mesos, terraform, bosh).
Design and user documents (in addition to our godoc generated documentation).
Examples for our applications and/or public libraries.
System init (systemd, upstart, sysv) and process manager/supervisor (runit, supervisord) configs.
Private application and library code.
Put our actual application code in the
/lib/app directory (e.g.,
/lib/app/bftx) and the code shared by those apps in the
/lib/pkg directory (e.g.,
Library code that's safe to use by third party applications (e.g.,
Other projects will import these libraries expecting them to work, so think twice before we put something here :-)
Blockfreight™ pluggable architechture support for third-party plugins.
Scripts to perform various build, install, analysis, etc operations.
These scripts keep the root level Makefile small and simple.
Additional external test apps and test data.
External helper tools, forked code and other 3rd party utilities (e.g., Swagger UI).
Supporting tools for this project. Note that these tools can import code from the
Application dependencies (managed manually or by our favorite dependency management tool).
Don't commit our application dependencies if we are building a library.
Web Application Directories
Web application specific components: static web assets, server side templates and SPAs.
Feedback to this project via Github Issues or email firstname.lastname@example.org
Package version is a package that defines the current version of the project.
|Package version is a package that defines the current version of the project.|
Starts the Blockfreight™ Node to listen to all requests in the Blockfreight Network.
|Starts the Blockfreight™ Node to listen to all requests in the Blockfreight Network.|
Initializes BFTX app to interacts with the Blockfreight™ Network.
|Initializes BFTX app to interacts with the Blockfreight™ Network.|
Package config is a package that handles with the application configutarions.
|Package config is a package that handles with the application configutarions.|
Package bf_tx is a package that defines the Blockfreight™ Transaction (BF_TX) transaction standard and provides some useful functions to work with the BF_TX.
|Package bf_tx is a package that defines the Blockfreight™ Transaction (BF_TX) transaction standard and provides some useful functions to work with the BF_TX.|
Package bft implements the main functions to work with the Blockfreight™ Network.
|Package bft implements the main functions to work with the Blockfreight™ Network.|
Package validator is a package that provides functions to assure the input JSON is correct.
|Package validator is a package that provides functions to assure the input JSON is correct.|
Package common provides some useful functions to work with the Blockfreight project.
|Package common provides some useful functions to work with the Blockfreight project.|
Package crypto provides useful functions to sign BF_TX.
|Package crypto provides useful functions to sign BF_TX.|
Package leveldb provides some useful functions to work with LevelDB.
|Package leveldb provides some useful functions to work with LevelDB.|
Package saberservice is a generated protocol buffer package.
|Package saberservice is a generated protocol buffer package.|