Sign inSign up

bpfk/agora

By bpfk

•Updated about 5 years ago

Node implementation for BOA CoinNet

Image
0

10K+

bpfk/agora repository overview

⁠Agora

Docker Hub image⁠

CircleCI codecov License Documentation

Node implementation for BOA CoinNet

⁠Docker usage

We provide a public build of this repository (see above). The easiest way to get agora is to run docker pull bpfk/agora.

The Dockerfile lives at the root of this repository, so one can run docker build -t agora . to build it. Note that you need to initialize submodules (git submodule update --init) before you first build agora.

For a test run, try:

docker run -p 127.0.0.1:4000:2826/tcp -v `pwd`/doc/:/agora/etc/ agora -c etc/config.example.yaml

This will start a node with the example config file, and make the port locally accessible (See http://127.0.0.1:4000/⁠) .

⁠Building on POSIX

⁠Dependencies

You need a recent C++ compiler (g++ with N4387 fixed), a recent (>=1.19.0) version of the LDC compiler, and dub. On Linux, we recommend gcc-9. On OSX, the latest llvm package available on Homebrew.

Additionally, the following are dependencies:

  • libsodium: Development library
  • pkg-config: For DUB to find the correct sqlite3 and other system libraries
  • openssl: Binary (to detect the version) and development library
  • sqlite3: Development library
  • zlib: Development library

Additionally, on OSX, PKG_CONFIG_PATH needs to be properly set to pick up sqlite3 and openssl. Provided you installed those packages via brew, you can run the following command prior to building:

export PKG_CONFIG_PATH="/usr/local/opt/sqlite/lib/pkgconfig:/usr/local/opt/[email protected]/lib/pkgconfig"

Since this setting does not persist, we recommend you follow Homebrew's instructions and add it to your .bashrc, .zshrc, etc...

⁠Build instructions

# Install the LDC compiler (you might want to use a newer version)
curl https://dlang.org/install.sh | bash -s ldc-1.24.0
# Add LDC to the $PATH
source ~/dlang/ldc-1.24.0/activate
# Clone this repository
git clone https://github.com/bpfkorea/agora.git
# Use the git root as working directory
cd agora/
# Initialize and update the list of submodules
git submodule update --init
# Build the application
dub build --skip-registry=all
# Build & run the tests
dub test --skip-registry=all

⁠Running tests

Agora comes with plenty of tests. Take a look at the CI configuration for an exact list. At the moment, the three main ways to run the test are:

  • dub test: Test the consensus protocol and runs all the unittests
  • rdmd tests/runner.d: Run a serie of simple integrations tests
  • ci/system_integration_test.d: Run a full-fledged system integration test, including building the docker image.

Tag summary

Content type

Image

Digest

Size

132.5 MB

Last updated

about 5 years ago

docker pull bpfk/agora