@constellation-network/node-pilot 0.12.6-devnet → 0.13.0-testnet
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
CHANGED
|
@@ -21,7 +21,7 @@ $ npm install -g @constellation-network/node-pilot
|
|
|
21
21
|
$ cpilot COMMAND
|
|
22
22
|
running command...
|
|
23
23
|
$ cpilot (--version|-v)
|
|
24
|
-
@constellation-network/node-pilot/0.
|
|
24
|
+
@constellation-network/node-pilot/0.13.0-testnet darwin-arm64 node-v22.15.0
|
|
25
25
|
$ cpilot --help [COMMAND]
|
|
26
26
|
USAGE
|
|
27
27
|
$ cpilot COMMAND
|
|
@@ -71,7 +71,7 @@ EXAMPLES
|
|
|
71
71
|
$ cpilot clean
|
|
72
72
|
```
|
|
73
73
|
|
|
74
|
-
_See code: [src/commands/clean.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.
|
|
74
|
+
_See code: [src/commands/clean.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.13.0-testnet/src/commands/clean.ts)_
|
|
75
75
|
|
|
76
76
|
## `cpilot config`
|
|
77
77
|
|
|
@@ -88,7 +88,7 @@ EXAMPLES
|
|
|
88
88
|
$ cpilot config
|
|
89
89
|
```
|
|
90
90
|
|
|
91
|
-
_See code: [src/commands/config.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.
|
|
91
|
+
_See code: [src/commands/config.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.13.0-testnet/src/commands/config.ts)_
|
|
92
92
|
|
|
93
93
|
## `cpilot config get [NAME]`
|
|
94
94
|
|
|
@@ -112,7 +112,7 @@ EXAMPLES
|
|
|
112
112
|
$ cpilot config get gl0:CL_PUBLIC_HTTP_PORT
|
|
113
113
|
```
|
|
114
114
|
|
|
115
|
-
_See code: [src/commands/config/get.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.
|
|
115
|
+
_See code: [src/commands/config/get.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.13.0-testnet/src/commands/config/get.ts)_
|
|
116
116
|
|
|
117
117
|
## `cpilot config set NAME VALUE`
|
|
118
118
|
|
|
@@ -135,7 +135,7 @@ EXAMPLES
|
|
|
135
135
|
$ cpilot config set gl0:CL_PUBLIC_HTTP_PORT 9000
|
|
136
136
|
```
|
|
137
137
|
|
|
138
|
-
_See code: [src/commands/config/set.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.
|
|
138
|
+
_See code: [src/commands/config/set.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.13.0-testnet/src/commands/config/set.ts)_
|
|
139
139
|
|
|
140
140
|
## `cpilot help [COMMAND]`
|
|
141
141
|
|
|
@@ -172,7 +172,7 @@ EXAMPLES
|
|
|
172
172
|
$ cpilot info
|
|
173
173
|
```
|
|
174
174
|
|
|
175
|
-
_See code: [src/commands/info.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.
|
|
175
|
+
_See code: [src/commands/info.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.13.0-testnet/src/commands/info.ts)_
|
|
176
176
|
|
|
177
177
|
## `cpilot logs LAYER`
|
|
178
178
|
|
|
@@ -198,7 +198,7 @@ EXAMPLES
|
|
|
198
198
|
$ cpilot logs
|
|
199
199
|
```
|
|
200
200
|
|
|
201
|
-
_See code: [src/commands/logs.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.
|
|
201
|
+
_See code: [src/commands/logs.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.13.0-testnet/src/commands/logs.ts)_
|
|
202
202
|
|
|
203
203
|
## `cpilot restart [LAYER]`
|
|
204
204
|
|
|
@@ -226,7 +226,7 @@ EXAMPLES
|
|
|
226
226
|
$ cpilot restart
|
|
227
227
|
```
|
|
228
228
|
|
|
229
|
-
_See code: [src/commands/restart.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.
|
|
229
|
+
_See code: [src/commands/restart.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.13.0-testnet/src/commands/restart.ts)_
|
|
230
230
|
|
|
231
231
|
## `cpilot shutdown`
|
|
232
232
|
|
|
@@ -243,7 +243,7 @@ EXAMPLES
|
|
|
243
243
|
$ cpilot shutdown
|
|
244
244
|
```
|
|
245
245
|
|
|
246
|
-
_See code: [src/commands/shutdown.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.
|
|
246
|
+
_See code: [src/commands/shutdown.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.13.0-testnet/src/commands/shutdown.ts)_
|
|
247
247
|
|
|
248
248
|
## `cpilot status`
|
|
249
249
|
|
|
@@ -257,5 +257,5 @@ DESCRIPTION
|
|
|
257
257
|
Display node status and configuration settings
|
|
258
258
|
```
|
|
259
259
|
|
|
260
|
-
_See code: [src/commands/status.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.
|
|
260
|
+
_See code: [src/commands/status.ts](https://github.com/Constellation-Labs/node-pilot/blob/v0.13.0-testnet/src/commands/status.ts)_
|
|
261
261
|
<!-- commandsstop -->
|
|
@@ -10,28 +10,11 @@ import { clusterService } from "../services/cluster-service.js";
|
|
|
10
10
|
import { dockerService } from "../services/docker-service.js";
|
|
11
11
|
import { shellService } from "../services/shell-service.js";
|
|
12
12
|
import { checkNetwork } from "./check-network.js";
|
|
13
|
-
/*
|
|
14
|
-
* -Xms12g \
|
|
15
|
-
-Xmx12g \
|
|
16
|
-
-XX:+UseZGC \
|
|
17
|
-
-XX:+ZGenerational \
|
|
18
|
-
-XX:ZAllocationSpikeTolerance=5 \
|
|
19
|
-
-XX:ZCollectionInterval=10 \
|
|
20
|
-
-XX:ConcGCThreads=4 \
|
|
21
|
-
-XX:ParallelGCThreads=8 \
|
|
22
|
-
-XX:+UseStringDeduplication \
|
|
23
|
-
--add-opens=java.base/java.lang.invoke=ALL-UNNAMED \
|
|
24
|
-
--add-opens=java.base/java.util=ALL-UNNAMED \
|
|
25
|
-
--add-opens=java.base/java.security=ALL-UNNAMED \
|
|
26
|
-
-XX:+HeapDumpOnOutOfMemoryError \
|
|
27
|
-
-XX:HeapDumpPath=./heap_dumps/ \
|
|
28
|
-
-XX:+ExitOnOutOfMemoryError
|
|
29
|
-
*/
|
|
30
13
|
function getJavaMemoryOptions(network, mem) {
|
|
31
14
|
if (network === 'testnet') {
|
|
32
15
|
const linuxOpt = (os.platform() === 'linux') ? ' -XX:+UseZGC -XX:+ZGenerational -XX:ZAllocationSpikeTolerance=5 -XX:ZCollectionInterval=10' : '';
|
|
33
16
|
// return `-Xms${mem}g -Xmx${mem}g -XX:+UnlockExperimentalVMOptions${linuxOpt} -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=./heap_dumps/ -XX:+ExitOnOutOfMemoryError`;
|
|
34
|
-
return `-Xms${mem}g -Xmx${mem}g${linuxOpt} -
|
|
17
|
+
return `-Xms${mem}g -Xmx${mem}g${linuxOpt} -XX:+UseStringDeduplication --add-opens=java.base/java.lang.invoke=ALL-UNNAMED --add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.base/java.security=ALL-UNNAMED`;
|
|
35
18
|
}
|
|
36
19
|
return `-Xms1024M -Xmx${mem}g -Xss256K`;
|
|
37
20
|
}
|
|
@@ -2,14 +2,10 @@ import semver from "semver";
|
|
|
2
2
|
import packageJson from '../../package.json' with { type: 'json' };
|
|
3
3
|
import { clm } from "../clm.js";
|
|
4
4
|
import { configStore } from "../config-store.js";
|
|
5
|
-
import shell from "shelljs";
|
|
6
|
-
import path from "node:path";
|
|
7
|
-
import { fileURLToPath } from "node:url";
|
|
8
|
-
import { projectHelper } from "../helpers/project-helper.js";
|
|
9
5
|
export const migrationService = {
|
|
10
6
|
runMigrations() {
|
|
11
7
|
const migrations = {
|
|
12
|
-
'0.12.
|
|
8
|
+
'0.12.5': m0125,
|
|
13
9
|
// add more migrations as needed
|
|
14
10
|
};
|
|
15
11
|
const { version = '0.0.0' } = configStore.getProjectInfo();
|
|
@@ -24,6 +20,7 @@ export const migrationService = {
|
|
|
24
20
|
const migrationVersions = Object.keys(migrations)
|
|
25
21
|
.filter(v => semver.gt(v, version) && semver.lte(v, currentVersion.version))
|
|
26
22
|
.sort(semver.compare);
|
|
23
|
+
// TODO shutdown node if migration is in progress
|
|
27
24
|
if (migrationVersions.length > 0) {
|
|
28
25
|
clm.preStep(`Migration versions to run: ${migrationVersions}`);
|
|
29
26
|
for (const version of migrationVersions) {
|
|
@@ -33,18 +30,20 @@ export const migrationService = {
|
|
|
33
30
|
configStore.setProjectInfo({ version: currentVersion.toString() });
|
|
34
31
|
}
|
|
35
32
|
};
|
|
36
|
-
function
|
|
37
|
-
clm.step('Running migration 0.12.
|
|
33
|
+
function m0125() {
|
|
34
|
+
clm.step('Running migration 0.12.5...');
|
|
38
35
|
configStore.setProjectFlag('javaMemoryChecked', false);
|
|
39
|
-
projectHelper.upgradeHypergraph();
|
|
40
|
-
installJava21();
|
|
41
|
-
}
|
|
42
|
-
function installJava21() {
|
|
43
|
-
const pilotDir = path.resolve(path.dirname(fileURLToPath(import.meta.url)), `../..`);
|
|
44
|
-
clm.debug(`Running install-java-21.sh from ${pilotDir}`);
|
|
45
|
-
const result = shell.exec('bash install-java-21.sh', { cwd: pilotDir });
|
|
46
|
-
if (result.code > 0) {
|
|
47
|
-
console.log(result.stderr);
|
|
48
|
-
clm.error(`Failed to install dependencies. Please try again after resolving any errors.`);
|
|
49
|
-
}
|
|
36
|
+
// projectHelper.upgradeHypergraph();
|
|
37
|
+
// installJava21();
|
|
50
38
|
}
|
|
39
|
+
// function installJava21() {
|
|
40
|
+
// const pilotDir = path.resolve(path.dirname(fileURLToPath(import.meta.url)), `../..`);
|
|
41
|
+
// clm.debug(`Running install-java-21.sh from ${pilotDir}`);
|
|
42
|
+
//
|
|
43
|
+
// const result = shell.exec('bash install-java-21.sh', {cwd: pilotDir});
|
|
44
|
+
//
|
|
45
|
+
// if (result.code > 0) {
|
|
46
|
+
// console.log(result.stderr);
|
|
47
|
+
// clm.error(`Failed to install dependencies. Please try again after resolving any errors.`);
|
|
48
|
+
// }
|
|
49
|
+
// }
|
package/oclif.manifest.json
CHANGED
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@constellation-network/node-pilot",
|
|
3
3
|
"description": "An easy deployment and monitoring tool for Constellation nodes.",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.13.0-testnet",
|
|
5
5
|
"author": "Frank Fox",
|
|
6
6
|
"bin": {
|
|
7
7
|
"cpilot": "bin/run.js"
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
"version": "oclif readme && git add README.md",
|
|
22
22
|
"start": "./bin/dev.js",
|
|
23
23
|
"debug": "DEBUG=true ./bin/dev.js",
|
|
24
|
-
"pub": "npm publish --access public --tag
|
|
24
|
+
"pub": "npm publish --access public --tag testnet"
|
|
25
25
|
},
|
|
26
26
|
"types": "dist/index.d.ts",
|
|
27
27
|
"engines": {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
FROM ubuntu:22.04
|
|
2
2
|
|
|
3
|
-
RUN apt update && apt install -y openjdk-
|
|
3
|
+
RUN apt update && apt install -y openjdk-21-jre
|
|
4
4
|
|
|
5
5
|
RUN apt install -y curl jq wget
|
|
6
6
|
|
|
@@ -39,7 +39,7 @@ COPY dist/gl0.jar /app/jars/gl0.jar
|
|
|
39
39
|
#COPY ./health-check /health-check
|
|
40
40
|
#RUN chmod +x /health-check/bin/run.sh
|
|
41
41
|
#RUN chmod +x /health-check/bin/hydrate.sh
|
|
42
|
-
RUN npm install -g "@constellation-network/node-pilot-health-check@0.0.
|
|
42
|
+
RUN npm install -g "@constellation-network/node-pilot-health-check@0.0.27"
|
|
43
43
|
|
|
44
44
|
# Add entrypoint
|
|
45
45
|
COPY ./entrypoint.sh /app/entrypoint.sh
|
|
@@ -8,7 +8,7 @@ services:
|
|
|
8
8
|
# volumes:
|
|
9
9
|
# - /var/run/docker.sock:/var/run/docker.sock
|
|
10
10
|
gl0:
|
|
11
|
-
image: constellationnetwork/tessellation${CL_DOCKER_CORE_REPO:-}:${DOCKER_IMAGE_VERSION:-
|
|
11
|
+
image: constellationnetwork/tessellation${CL_DOCKER_CORE_REPO:-}:${DOCKER_IMAGE_VERSION:-test}
|
|
12
12
|
networks:
|
|
13
13
|
- tessellation-network
|
|
14
14
|
restart: unless-stopped
|
|
@@ -33,7 +33,7 @@ services:
|
|
|
33
33
|
# labels:
|
|
34
34
|
# autoheal: "true"
|
|
35
35
|
gl1:
|
|
36
|
-
image: constellationnetwork/tessellation${CL_DOCKER_CORE_REPO:-}:${DOCKER_IMAGE_VERSION:-
|
|
36
|
+
image: constellationnetwork/tessellation${CL_DOCKER_CORE_REPO:-}:${DOCKER_IMAGE_VERSION:-test}
|
|
37
37
|
restart: unless-stopped
|
|
38
38
|
networks:
|
|
39
39
|
- tessellation-network
|