💸 CryptoCurrency for all
Clone or download
Pull request Compare This branch is 39 commits ahead, 37 commits behind ArkEcosystem:mainnet.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
docs first iteration multiple network support May 5, 2017
helpers update seeds and fix bug. Jul 19, 2018
logic fixed wrong call May 16, 2017
logs Adding logs / pids directories. Aug 6, 2016
modules fix wrong pr. People should really think twice before merging non-wor… Jul 19, 2018
optional improved dashboard Mar 3, 2017
pids Adding logs / pids directories. Aug 6, 2016
schema fix on recipientId not being ark address Mar 30, 2017
sql Pull request #90: 127.0.0.1 loopback Jun 14, 2018
tasks added proper devnet config May 16, 2017
test first iteration multiple network support May 5, 2017
views small fixes Mar 9, 2017
.gitignore adding docs Feb 28, 2017
.gitmodules fixing all tests Dec 6, 2016
.jshintignore Ignoring file. Aug 22, 2016
.jshintrc Adding global. ✓ 54 files lint free. Aug 22, 2016
Gruntfile.js 3rd iteration with smart transaction application Jan 27, 2017
README.md Update README.md Sep 29, 2017
Vagrantfile initial version of Vagrant Dec 5, 2016
app.js added 1.0.4 watchguard. Jul 19, 2018
build Initial commit. Feb 1, 2016
config.devnet.json added proper devnet config May 16, 2017
config.json first iteration on bridge app Mar 1, 2017
config.main.json rebrand wip Oct 11, 2016
config.mainnet.json Update config.mainnet.json Sep 19, 2018
config.selftest.json updated to new testnet Jan 19, 2017
config.testnet.json Update config.testnet.json Sep 22, 2017
genesisBlock.devnet.json devnet conf May 5, 2017
genesisBlock.json first iteration for HD wallet support version Jan 11, 2017
genesisBlock.main.json initial ark rebrand and simplification Oct 8, 2016
genesisBlock.mainnet.json Add files via upload Sep 17, 2017
genesisBlock.testnet.json first iteration multiple network support May 5, 2017
logger.js iteration 4 - changed tx id, added fees to tx hash, enable variable f… Jan 30, 2017
networks.json Update networks.json Jun 18, 2017
package.json added 1.0.4 watchguard. Jul 19, 2018

README.md

KAPU NODE 1.1

KAPU is an Ark Fork, it's a next generation crypto-currency and a decentralized application platform, written entirely in JavaScript.

This version is still alpha, use at your own risks

Install, Upgrade etc...

You need to provision a linux (ubuntu tested) server (digital ocean, vultur or other).

For developers, please read below in section "Developer Installation"

Details

This is a fork from Lisk with the following features:

  • Removed sidechains (deprecated in favor of smartbridge)
  • Removed custom node version
  • Removed UI for stability and security reasons
  • Changed some constants (block rewards, blocktime etc...)
  • Added simple PBFT before forging new block
  • Ditch addresses from the protocol in favor of bitcoin like system, enabling HD Wallet as for BIP32
  • Completely rewritten node management using a single NodeManager and messaging system
  • Completely rewritten round management (removed mem_round, reward block fees to forger)
  • Added 64 bytes vendorField as first iteration of smart bridge
  • Made peers management entirely in-memory for efficiency
  • Strengthened the transaction management and broadcast (reject often, reject soon)
  • Rearchitect with relay nodes and forging nodes
  • Nodes broadcast only block headers.

### Planned features:

  • Simple blockchain validation for SPV and use in lite clients
  • Add IPFS as first class citizen (using smartbridge addressing)
  • Protocol improvements (uncle forging, voting weights).
  • Remove unsecured API
  • Routing tables

### Performance

  • stable on testnet at 5tx/s
  • pushed to 10tx/s on devnet

Automatic Installation KAPU Node "MainNet"

Create New User

adduser your_user
adduser your_user sudo
su - your_user 
wget http://kapu.one/KAPUshell_main.bash

bash KAPUshell_main.bash

For Restore Last Blockchain

Dgt "4" Rebuild Database


Developer Installation

Create New User

adduser your_user
adduser your_user sudo
su - your_user 

Install essentials:

sudo apt-get update
sudo apt-get install -y curl build-essential python git

Install PostgreSQL (min version: 9.5.2)

sudo apt-get install -y postgresql postgresql-contrib libpq-dev 
sudo -u postgres psql -c "CREATE USER $USER WITH PASSWORD 'password';"
sudo su postgres
createdb kapu_mainnet
exit 

Install Node.js (tested with version 6.9.2, but any recent LTS release should do):

sudo apt-get install -y nodejs
sudo apt-get install npm -y
sudo npm install -g n
sudo n 6.9.2

Install grunt-cli (globally):

sudo npm install grunt-cli -g

Clone this repository

git clone https://github.com/kapucoin/kapu-node.git
cd kapu-node

Install node modules:

npm install libpq secp256k1
npm install

Launch

To launch Kapu on MainNet:

Edit config.mainnet.json  you Secret Passrh

Node is running from:

sudo npm install forever -g
forever start app.js -c ./config.mainnet.json -g ./genesisBlock.mainnet.json

Open Ark Wallet 1.25

Create New

Automatic Installation KAPU Node "TestNet"

Create New User

adduser your_user
adduser your_user sudo
su - your_user 
wget http://kapu.one/KAPUshell.sh

bash KAPUshell.sh

For Restore Last Blockchain

Dgt "4" Rebuild Database


NOTE: The port, address, genesis block and config-path can be overridden by providing the relevant command switch:

node app.js -p [port] -a [address] -c [config-path] -g [genesisBlock-path]

This allow you to run several different networks, or your own private chain

Launch your own private or public chain

Generate a genesisBlock.json + a default config.json containing all passphrases of genesis delegates

node tasks/createGenesisBlock.js

You can find generated files in tasks/

  • genesisBlock.json
  • config.json
  • delegatesPassphrases.json (containing details about the genesis delegates)
  • genesisPassphrase.json (containing the details of account having all premined arks)

Obviously you can hack away tasks/createGenesisBlock.js for your own custom use.

You can the start with your own chain on a single node (all delegates will forge on your single node) using:

createdb ark_newtest
npm run start:newtest

Then you can distribute the config.json (without the delegates secrets inside, and with custom peers settings) to peers to let them join your chain

Tests

Load git submodule ark-js:

git submodule init
git submodule update

You should run using test configurations

npm run start:test

Run the test suite:

npm test

Run individual tests:

npm test -- test/api/accounts.js
npm test -- test/api/transactions.js

NOTE: The master passphrase for this test genesis block is as follows:

peace vanish bleak box tuna woman rally manage undo royal lucky since

Authors

License

The MIT License (MIT)

Copyright (c) 2016 Ark Copyright (c) 2016 Lisk Copyright (c) 2014-2015 Crypti

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.