Skip to content

Commit

Permalink
Merge pull request #226 from nemtech/dev
Browse files Browse the repository at this point in the history
Dev -> Main
  • Loading branch information
rg911 authored Apr 13, 2021
2 parents 03a20ac + 76d246e commit 3ac5c1b
Show file tree
Hide file tree
Showing 93 changed files with 8,686 additions and 7,177 deletions.
8 changes: 7 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
dist: bionic
language: node_js
node_js:
- 10
- 12
- lts/*
- node
services:
- docker
env:
global:
- DOCKER_COMPOSE_VERSION=1.25.0
- DEV_BRANCH=dev
- RELEASE_BRANCH=main
- POST_RELEASE_BRANCH=main
Expand All @@ -17,6 +19,10 @@ cache:
- node_modules
- .eslintcache
before_script:
- sudo rm /usr/local/bin/docker-compose
- curl -L https://github.com/docker/compose/releases/download/${DOCKER_COMPOSE_VERSION}/docker-compose-`uname -s`-`uname -m` > docker-compose
- chmod +x docker-compose
- sudo mv docker-compose /usr/local/bin
- . ./travis/node-functions.sh
- VERSION="$(node_load_version)"
- if [[ ! -z "$DOCKER_USERNAME" ]] ; then echo "${DOCKER_PASSWORD}" | docker login -u "${DOCKER_USERNAME}" --password-stdin; fi
Expand Down
16 changes: 16 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,22 @@ All notable changes to this project will be documented in this file.

The changelog format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).

## [1.0.4] - NEXT

**Milestone**: Mainnet(1.0.0.0)

| Package | Version | Link |
| ---------------- | ------- | ------------------------------------------------------------------ |
| Symbol Bootstrap | v1.0.4 | [symbol-bootstrap](https://www.npmjs.com/package/symbol-bootstrap) |

- New `testnet.symboldev.network` testnet!
- Added `verify` command.
- Fixed host override when no custom preset is provided in mainnet.
- Fixed case issue validating keys when creating certificates.
- Updated Wallet to latest 1.0.1 release.
- Node properties sinkType: Async and enableSingleThreadPool: false by default in peer nodes too.
- Dropped NodeJS 10 support. Added Node LTS and Stable Support.

## [1.0.3] - Mar-31-2021

**Milestone**: Mainnet(1.0.0.0)
Expand Down
19 changes: 9 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,21 +87,19 @@ The folder where the generated config, docker files and data are stored. The fol
- `./gateways`: it holds the configuration and logs for all the defined node rest gateways.
- `./nemesis`: The folder used to hold the nemesis block. Block 1 data is generated via `nemgen` tool for new networks. For existing network, it is copied over.
- `./databases`: the location where the mongo data is stored for the different database instances.
- `./docker`: the generated docker-compose.yml, mongo init scripts and server basic bash scripts.
- `./docker`: the generated docker-compose.yml, mongo init scripts and server basic bash scripts.
- `./reports`: the location of the generated reports.

# Requirements

- Node 10+
- Docker
- Docker Compose
- Node 12.0.0+
- Docker 18.3.0+
- Docker Compose 1.25.0+

Validate your environment by running:

```
node -v
docker -v
docker-compose -v
symbol-bootstrap verify
```

Check your user can run docker without sudo:
Expand Down Expand Up @@ -137,7 +135,7 @@ $ npm install -g symbol-bootstrap
$ symbol-bootstrap COMMAND
running command...
$ symbol-bootstrap (-v|--version|version)
symbol-bootstrap/1.0.3 linux-x64 node-v10.24.0
symbol-bootstrap/1.0.4 linux-x64 node-v12.18.4
$ symbol-bootstrap --help [COMMAND]
USAGE
$ symbol-bootstrap COMMAND
Expand Down Expand Up @@ -216,8 +214,8 @@ Alternatively, you can use the [BootstrapService](https://github.com/nemtech/sym
Example:

```ts
import {BootstrapService, StartParams, Preset} from 'symbol-bootstrap';
import {expect} from '@oclif/test';
import {BootstrapService, StartParams, Preset} from 'symbol-bootstrap';
import {expect} from '@oclif/test';

it('Bootstrap e2e test', async () => {
const service = new BootstrapService();
Expand Down Expand Up @@ -279,6 +277,7 @@ General users should install this tool like any other node module.
* [`symbol-bootstrap run`](docs/run.md) - It boots the network via docker using the generated `docker-compose.yml` file and configuration. The config and compose methods/commands need to be called before this method. This is just a wrapper for the `docker-compose up` bash call.
* [`symbol-bootstrap start`](docs/start.md) - Single command that aggregates config, compose and run in one line!
* [`symbol-bootstrap stop`](docs/stop.md) - It stops the docker-compose network if running (symbol-bootstrap started with --detached). This is just a wrapper for the `docker-compose down` bash call.
* [`symbol-bootstrap verify`](docs/verify.md) - It tests the installed software in the current computer reporting if there is any missing dependency, invalid version, or software related issue.

<!-- commandsstop -->

Expand Down
3 changes: 3 additions & 0 deletions cmds/start-testnet-demo.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/bash
set -e
symbol-bootstrap start -p testnet -a demo -t target/testnet-demo --noPassword $1 $2 $3
3 changes: 3 additions & 0 deletions cmds/start-testnet-supernode-demo.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/bash
set -e
symbol-bootstrap start -p testnet -a demo -t target/testnet-supernode -c test/supernode.yml $1 $2 $3
3 changes: 2 additions & 1 deletion cmds/start-testnet-supernode.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#!/bin/bash
set -e
symbol-bootstrap start -p testnet -a dual -t target/testnet-supernode -c test/supernode.yml $1 $2 $3
symbol-bootstrap config -p testnet -a dual -t target/testnet-supernode -c test/supernode.yml -r --password 1111 $1 $2 $3
symbol-bootstrap start --password 1111 --upgrade -t target/testnet-supernode
3 changes: 2 additions & 1 deletion config/wallet/app.conf.js.mustache
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ var appConfig = {
MAX_SEED_ACCOUNTS_NUMBER: 10,
MIN_PASSWORD_LENGTH: 8,
SEED_ACCOUNT_NAME_PREFIX: 'SeedWallet-',
ANNOUNCE_TRANSACTION_TIMEOUT: 120000,
ANNOUNCE_TRANSACTION_TIMEOUT: 240000,
DECIMAL_SEPARATOR: Number('1.1').toLocaleString().substring(1, 2),
},
languages: [
{ value: 'en-US', label: 'English' },
Expand Down
11 changes: 4 additions & 7 deletions config/wallet/fees.conf.js.mustache
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
var feesConfig = {
median: 1,
highest: 2,
median: 10,
free: 0,
slowest: 5000,
slow: 30000,
normal: 50000,
fast: 100000,
fastest: 1000000,
slow: 5,
slowest: 1,
fast: 20,
}
window.feesConfig = feesConfig
console.log('feesConfig loaded!', feesConfig)
8 changes: 5 additions & 3 deletions config/wallet/network.conf.js.mustache
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
var networkConfig = {
var networkTypeConfig = {
"explorerUrl": "{{{explorerUrl}}}",
"faucetUrl": "{{{faucetUrl}}}",
"defaultNetworkType": {{{networkType}}},
"defaultNodeUrl": "{{{defaultNodeUrl}}}",
"networkConfigurationDefaults": {
"epochAdjustment": {{{toSeconds epochAdjustment}}},
"maxMosaicDivisibility": {{{maxMosaicDivisibility}}},
"namespaceGracePeriodDuration": {{{toSeconds namespaceGracePeriodDuration}}},
"lockedFundsPerAggregate": "{{{lockedFundsPerAggregate}}}",
Expand All @@ -21,14 +20,17 @@ var networkConfig = {
"currencyMosaicId": "{{{toSimpleHex currencyMosaicId}}}",
"harvestingMosaicId": "{{{toSimpleHex harvestingMosaicId}}}",
"defaultDynamicFeeMultiplier": {{{defaultDynamicFeeMultiplier}}},
"epochAdjustment": {{{toSeconds epochAdjustment}}}
"epochAdjustment": {{{toSeconds epochAdjustment}}},
"totalChainImportance": {{totalChainImportance}},
"generationHash": "{{nemesisGenerationHashSeed}}"
},
"nodes": [
{{#restNodes}}
{"friendlyName": "{{{friendlyName}}}", "roles": {{{roles}}}, "url": "{{{url}}}"},
{{/restNodes}}
]
}
var networkConfig = { {{{networkType}}} : networkTypeConfig }
window.networkConfig = networkConfig
console.log('networkConfig loaded!', networkConfig)

Expand Down
2 changes: 1 addition & 1 deletion docs/clean.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ EXAMPLE
$ symbol-bootstrap clean
```

_See code: [src/commands/clean.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.3/src/commands/clean.ts)_
_See code: [src/commands/clean.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.4/src/commands/clean.ts)_
2 changes: 1 addition & 1 deletion docs/compose.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,4 @@ EXAMPLE
$ symbol-bootstrap compose
```

_See code: [src/commands/compose.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.3/src/commands/compose.ts)_
_See code: [src/commands/compose.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.4/src/commands/compose.ts)_
8 changes: 5 additions & 3 deletions docs/config.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,16 @@ USAGE
$ symbol-bootstrap config
OPTIONS
-a, --assembly=assembly An optional assembly type, example "dual" for testnet
-a, --assembly=assembly The assembly, example "dual" for testnet. If not provided, the value is
resolved from the target/preset.yml file.
-c, --customPreset=customPreset External preset file. Values in this file will override the provided presets
(optional)
-h, --help It shows the help of this command.
-p, --preset=(bootstrap|testnet|mainnet) [default: bootstrap] the network preset
-p, --preset=(bootstrap|testnet|mainnet) The network preset, can be provided via custom preset or cli parameter. If
not provided, the value is resolved from the target/preset.yml file.
-r, --reset It resets the configuration generating a new one
Expand Down Expand Up @@ -57,4 +59,4 @@ EXAMPLES
$ echo "$MY_ENV_VAR_PASSWORD" | symbol-bootstrap config -p testnet -a dual
```

_See code: [src/commands/config.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.3/src/commands/config.ts)_
_See code: [src/commands/config.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.4/src/commands/config.ts)_
2 changes: 1 addition & 1 deletion docs/decrypt.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,4 +56,4 @@ EXAMPLES
plain-addresses.yml
```

_See code: [src/commands/decrypt.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.3/src/commands/decrypt.ts)_
_See code: [src/commands/decrypt.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.4/src/commands/decrypt.ts)_
2 changes: 1 addition & 1 deletion docs/encrypt.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,4 +46,4 @@ EXAMPLES
encrypted-custom-preset.yml
```

_See code: [src/commands/encrypt.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.3/src/commands/encrypt.ts)_
_See code: [src/commands/encrypt.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.4/src/commands/encrypt.ts)_
2 changes: 1 addition & 1 deletion docs/enrolRewardProgram.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,4 +47,4 @@ EXAMPLES
$ echo "$MY_ENV_VAR_PASSWORD" | symbol-bootstrap enrolRewardProgram --url http://external-rest:3000
```

_See code: [src/commands/enrolRewardProgram.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.3/src/commands/enrolRewardProgram.ts)_
_See code: [src/commands/enrolRewardProgram.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.4/src/commands/enrolRewardProgram.ts)_
2 changes: 1 addition & 1 deletion docs/healthCheck.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,4 @@ EXAMPLE
$ symbol-bootstrap healthCheck
```

_See code: [src/commands/healthCheck.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.3/src/commands/healthCheck.ts)_
_See code: [src/commands/healthCheck.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.4/src/commands/healthCheck.ts)_
2 changes: 1 addition & 1 deletion docs/link.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,4 @@ EXAMPLES
$ echo "$MY_ENV_VAR_PASSWORD" | symbol-bootstrap link --unlink --useKnownRestGateways
```

_See code: [src/commands/link.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.3/src/commands/link.ts)_
_See code: [src/commands/link.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.4/src/commands/link.ts)_
2 changes: 1 addition & 1 deletion docs/report.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ EXAMPLE
$ symbol-bootstrap report
```

_See code: [src/commands/report.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.3/src/commands/report.ts)_
_See code: [src/commands/report.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.4/src/commands/report.ts)_
2 changes: 1 addition & 1 deletion docs/resetData.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ EXAMPLE
$ symbol-bootstrap resetData
```

_See code: [src/commands/resetData.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.3/src/commands/resetData.ts)_
_See code: [src/commands/resetData.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.4/src/commands/resetData.ts)_
2 changes: 1 addition & 1 deletion docs/run.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,4 +53,4 @@ EXAMPLE
$ symbol-bootstrap run
```

_See code: [src/commands/run.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.3/src/commands/run.ts)_
_See code: [src/commands/run.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.4/src/commands/run.ts)_
7 changes: 4 additions & 3 deletions docs/start.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ USAGE
OPTIONS
-a, --assembly=assembly
An optional assembly type, example "dual" for testnet
The assembly, example "dual" for testnet. If not provided, the value is resolved from the target/preset.yml file.
-b, --build
If provided, docker-compose will run with -b (--build)
Expand All @@ -31,7 +31,8 @@ OPTIONS
It shows the help of this command.
-p, --preset=(bootstrap|testnet|mainnet)
[default: bootstrap] the network preset
The network preset, can be provided via custom preset or cli parameter. If not provided, the value is resolved from
the target/preset.yml file.
-r, --reset
It resets the configuration generating a new one
Expand Down Expand Up @@ -89,4 +90,4 @@ EXAMPLES
$ echo "$MY_ENV_VAR_PASSWORD" | symbol-bootstrap start -p testnet -a dual
```

_See code: [src/commands/start.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.3/src/commands/start.ts)_
_See code: [src/commands/start.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.4/src/commands/start.ts)_
2 changes: 1 addition & 1 deletion docs/stop.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ EXAMPLE
$ symbol-bootstrap stop
```

_See code: [src/commands/stop.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.3/src/commands/stop.ts)_
_See code: [src/commands/stop.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.4/src/commands/stop.ts)_
23 changes: 23 additions & 0 deletions docs/verify.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
`symbol-bootstrap verify`
=========================

It tests the installed software in the current computer reporting if there is any missing dependency, invalid version, or software related issue.

* [`symbol-bootstrap verify`](#symbol-bootstrap-verify)

## `symbol-bootstrap verify`

It tests the installed software in the current computer reporting if there is any missing dependency, invalid version, or software related issue.

```
USAGE
$ symbol-bootstrap verify
OPTIONS
-h, --help It shows the help of this command.
EXAMPLE
$ symbol-bootstrap verify
```

_See code: [src/commands/verify.ts](https://github.com/nemtech/symbol-bootstrap/blob/v1.0.4/src/commands/verify.ts)_
Loading

0 comments on commit 3ac5c1b

Please sign in to comment.