Skip to content

Open-Earth-Foundation/openfinance

Repository files navigation

OpenX

Build Status Codecov Go Report Card

Openx is a project hosted at the MIT Media Lab Digital Currency Initiative and the Yale Open Innonvation Lab. The openx model seeks to implement the paradigm of investing in and developing projects without hassles, and enabling smart ownership with the help of the blockchain. Openx can be thought of as a platform of platforms and houses multiple platforms within it.

The goal of openx is to have a common interface between all parties that relate to a project: Investors, Recipients, Developers, an dOriginators. A running pilot of openx is at opensolar

Related Repositories

Openx
Opensolar
Opensolar Frontend
API Docs
Wiki
Create-openx-app
Openx-CLI

Related Websites

Demo
Openx API
Opensolar API
API docs
Wiki
Builds
MQTT broker
Pilot Dashboard

Getting Started

Download

Openx builds are available at builds.openx.solar

Docker image available at Docker Hub

Installing from PPA

Openx is available on PPA here. Warning: The PPA might not be up to date.

Building from source

Requirements:

  1. Go 1.11 and above
  2. Standard build tools depending on architecture (build-essential for linux, brew and xcode dev tools for mac)

IMPORTANT: Inline with the Golang dev team, we will not be supporting versions of go that are more than two releases old. If you have a version of Go that is older than 1.11, please upgrade to the latest version of Go before continuing.

go get -v github.com/YaleOpenLab/openx
cd $GOPATH/src/github.com/YaleOpenLab/openx/
go mod download
go mod verify
go build

Make sure you have the necessary permissions to write to $HOME. Start openx using ./openx

Installing IPFS

ipfs is used by some parts of the program to store data that needs to be publicly verified.

Download a release from https://github.com/ipfs/go-ipfs/releases and run install.sh. If you face conflicts between multiple ipfs versions, you might need to run fs-repo-migrations to migrate to the newer version. If you don't have anything worth storing, you can delete the ipfs home directory and run ipfs init again (this will delete the data stored in ipfs prior to deletion)

You need to keep your peer key (ipfs.key usually) in a safe place for future reference. Start ipfs using ipfs daemon and you can test it by creating a file test.txt and run ipfs add test.txt. The resultant hash can be decrypted using curl "http://127.0.0.1:8080/ipfs/hash" where 127:0.0.1:8080 is the endpoint of the ipfs server. If you need more help on setting up ipfs, you can also refer to this helpful tutorial.

Running tests

Running tests is simple with go test but tests have flags since some require running daemons in the background (eg. ipfs). There are two kinds of flags - travis and all.

If you need coverage stats as well, you need to install cover as well. go get golang.org/x/tools/cmd/cover if you don't have the package. Running go test --tags="travis" -coverprofile=test.txt ./... should run all the tests and provide coverage data on each specific package.

Contributing

Please feel free to open Pull Requests and Issues with your changes and suggestions. Before working on a major feature, please describe the same in an issue so everyone can understand what you're building.

Security

For security related issues, DO NOT OPEN A GITHUB ISSUE!. Please disclose the information responsibly by sending a (preferably PGP Encrypted) email to the lead developer Varunram Ganesh (contact@varunram.com). His PGP Key fingerprint is C98F 0014 9A99 36E4 E56D 2471 708C 6065 04A4 9970

In addition to this, openx is fully fully compliant with the disclose.io core terms followed by bugcrowd. For more info, please checkout SECURITY.md

License

GPL3