From 254619e5dd90af6d1e551b2c0771b2c7f7045f27 Mon Sep 17 00:00:00 2001 From: vaultec <47548474+vaultec81@users.noreply.github.com> Date: Tue, 27 Feb 2024 16:02:24 -0800 Subject: [PATCH] feat: first marked version, broadcast version --- package.json | 2 +- src/services/new/witness/versionManager.ts | 6 ++++-- src/services/nodeInfo.ts | 2 ++ 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index 19ad35e..91808c4 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@vaultec/vsc-node", - "version": "1.0.0", + "version": "0.1.0", "description": "", "main": "dist/index.js", "dependencies": { diff --git a/src/services/new/witness/versionManager.ts b/src/services/new/witness/versionManager.ts index 759ac47..78b6156 100644 --- a/src/services/new/witness/versionManager.ts +++ b/src/services/new/witness/versionManager.ts @@ -5,8 +5,10 @@ import { Collection } from "mongodb"; -const VersionConfig = { - index_reset_id: 2 +export const VersionConfig = { + index_reset_id: 2, + //Match with package.json and tag + version_id: 'v0.1.0' } /** diff --git a/src/services/nodeInfo.ts b/src/services/nodeInfo.ts index 6218d38..1a00fc2 100644 --- a/src/services/nodeInfo.ts +++ b/src/services/nodeInfo.ts @@ -4,6 +4,7 @@ import { getCommitHash, HiveClient, ModuleContainer } from "../utils"; import { CoreService, } from "./index"; import moment from "moment"; import { Collection } from "mongodb"; +import { VersionConfig } from "./new/witness/versionManager"; export class NodeInfoService { @@ -102,6 +103,7 @@ export class NodeInfoService { ts: new Date().toISOString(), hive_account: hiveAccount, git_commit: this.gitCommit, + version_id: VersionConfig.version_id, witness: { enabled: witnessEnabled, disabled_reason: disableReason,