From bd9c76498ac9fd56a40bbfdb78261c03361a77a0 Mon Sep 17 00:00:00 2001 From: POPPIN-FUMI Date: Mon, 21 Oct 2024 19:41:36 +0200 Subject: [PATCH] Update Solana Testnet Version v2.0.14 --- .changeset/mighty-seahorses-kick.md | 44 +++++++++++++++++++++++ packages/solv/src/cli/update/index.ts | 37 +++++-------------- packages/solv/src/config/versionConfig.ts | 9 ++--- 3 files changed, 58 insertions(+), 32 deletions(-) create mode 100644 .changeset/mighty-seahorses-kick.md diff --git a/.changeset/mighty-seahorses-kick.md b/.changeset/mighty-seahorses-kick.md new file mode 100644 index 00000000..dd1cd5eb --- /dev/null +++ b/.changeset/mighty-seahorses-kick.md @@ -0,0 +1,44 @@ +--- +'@epics-dao/solv': patch +--- + +Update Solana Testnet Version v2.0.14 + +- For users who are not using solv Auto Operation Mode: Please follow the instructions below. + +```bash +$ solv update && solv update -b +``` + +## How to use solv Auto Operation Mode? + +Run the following command: + +```bash +$ solv auto +? Do you want to enable solv Auto Operation Mode?(You can change it again) (y/N) +? Do you want to enable AUTO UPDATE? (Recommended) (y/N) +? Do you want to enable AUTO RESTART? (Recommended) (y/N) +※ Please turn off if you are using no-downtime migration. +? Enter your Discord Webhook URL (https://discord.com/api/webhooks/1234) +``` + +1. Enable solv Auto Operation Mode. +2. Enable AUTO UPDATE. +3. Enable AUTO RESTART. + ※ Please turn off if you are using no-downtime migration. + ※ No-downtime migration requires spare server and manual restart. +4. Enter your Discord Webhook URL. + ※ You can receive notifications about the Solana/solv version update. +5. Enter RPC URL (Mainnet Only) +6. Enter Harvest Account (Mainnet Only) + +## How to disable solv Auto Operation Mode? + +Run the following command: + +```bash +$ solv auto +? Do you want to enable solv Auto Operation Mode?(You can change it again) (y/N) n +✅ Cron Job successfully removed. +``` diff --git a/packages/solv/src/cli/update/index.ts b/packages/solv/src/cli/update/index.ts index 24d7e1e8..ba569b48 100644 --- a/packages/solv/src/cli/update/index.ts +++ b/packages/solv/src/cli/update/index.ts @@ -18,6 +18,8 @@ import { ValidatorType, } from '@/config/enums' import { + DELINQUENT_STAKE_MAINNET, + DELINQUENT_STAKE_TESTNET, VERSION_JITO_MAINNET, VERSION_JITO_RPC, VERSION_JITO_TESTNET, @@ -27,12 +29,6 @@ import { } from '@/config/versionConfig' import { readOrCreateDefaultConfig } from '@/lib/readOrCreateDefaultConfig' import { MAINNET_TYPES, NETWORK_TYPES, SOLV_TYPES } from '@/config/config' -import { rmSnapshot } from '../setup/rmSnapshot' -import createSnapshot from '../get/createSnapshot' -import { startTestnetAgaveValidatorScript } from '@/template/startupScripts/startTestnetAgaveValidatorScript' -import { writeFile } from 'fs/promises' -import { spawnSync } from 'node:child_process' -import { STARTUP_SCRIPT } from '@/config/constants' export * from './update' @@ -169,28 +165,13 @@ export const updateCommands = (config: DefaultConfigType) => { await monitorUpdate(deliquentStake, true) return } - if (isTestnet) { - // Restart Instruction - // https://github.com/anza-xyz/agave/wiki/2024-10-16-Testnet-Rollback-and-Restart - spawnSync(`solv stop`, { shell: true, stdio: 'inherit' }) - spawnSync(`agave-install init v1.18.26`, { - shell: true, - stdio: 'inherit', - }) - try { - createSnapshot() - } catch (error) { - rmSnapshot() - } - const script = startTestnetAgaveValidatorScript() - await writeFile(STARTUP_SCRIPT, script, { mode: 0o755 }) - spawnSync(`solv start`, { shell: true, stdio: 'inherit' }) - console.log(chalk.white(`Successfully Updated!`)) - } else { - await updateVersion(version) - await monitorUpdate(deliquentStake, true) - return - } + + await updateVersion(version) + const deliquentStakeNum = isTestnet + ? DELINQUENT_STAKE_TESTNET + : DELINQUENT_STAKE_MAINNET + await monitorUpdate(deliquentStakeNum, true) + return } else if (options.commission) { const ansewr = await updateCommissionAsk() updateCommission(ansewr.commission, isTestnet) diff --git a/packages/solv/src/config/versionConfig.ts b/packages/solv/src/config/versionConfig.ts index 3a65717b..9c9f4cb8 100644 --- a/packages/solv/src/config/versionConfig.ts +++ b/packages/solv/src/config/versionConfig.ts @@ -1,11 +1,12 @@ -export const VERSION_TESTNET = '1.18.26' +export const VERSION_TESTNET = '2.0.14' export const VERSION_MAINNET = '1.18.25' -export const VERSION_JITO_TESTNET = '2.0.10' +export const VERSION_JITO_TESTNET = '2.0.14' export const VERSION_JITO_MAINNET = '1.18.25' export const VERSION_JITO_RPC = '2.0.10' -export const VERSION_SOLANA_RPC = '2.0.13' -export const DELINQUENT_STAKE_TESTNET = 5 +export const VERSION_SOLANA_RPC = '2.0.14' +export const DELINQUENT_STAKE_TESTNET = 15 export const DELINQUENT_STAKE_MAINNET = 5 export const COMMISSION = 5 export const VERSION_NODE = '20.17.0' +export const VERSION_FIREDANCER_MAINNET = '0.114.20013' export const VERSION_FIREDANCER = '0.114.20013'