Skip to content

Commit

Permalink
feat: Increase helm chart version and switch to use oci registry (#788)
Browse files Browse the repository at this point in the history
Signed-off-by: Jeffrey Tang <[email protected]>
  • Loading branch information
JeffreyDallas authored Nov 6, 2024
1 parent dac8fb6 commit 1973275
Show file tree
Hide file tree
Showing 9 changed files with 18 additions and 12 deletions.
8 changes: 6 additions & 2 deletions src/commands/cluster.ts
Original file line number Diff line number Diff line change
Expand Up @@ -120,11 +120,15 @@ export class ClusterCommand extends BaseCommand {
const clusterSetupNamespace = ctx.config.clusterSetupNamespace
const version = ctx.config.soloChartVersion

const chartPath = ctx.chartPath
const chartPath = constants.SOLO_TESTING_CHART_URL + constants.SOLO_CLUSTER_SETUP_CHART
const valuesArg = ctx.valuesArg

try {
await self.chartManager.install(clusterSetupNamespace, constants.SOLO_CLUSTER_SETUP_CHART, chartPath, version, valuesArg)
self.logger.debug(`Installing chart chartPath = ${chartPath}, version = ${version}`)
await self.chartManager.install(clusterSetupNamespace,
constants.SOLO_CLUSTER_SETUP_CHART,
chartPath,
version, valuesArg)
} catch (e: Error | any) {
// if error, uninstall the chart and rethrow the error
self.logger.debug(`Error on installing ${constants.SOLO_CLUSTER_SETUP_CHART}. attempting to rollback by uninstalling the chart`, e)
Expand Down
4 changes: 2 additions & 2 deletions src/commands/network.ts
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,7 @@ export class NetworkCommand extends BaseCommand {
await this.chartManager.install(
config.namespace,
constants.SOLO_DEPLOYMENT_CHART,
config.chartPath,
constants.SOLO_TESTING_CHART_URL + constants.SOLO_DEPLOYMENT_CHART,
config.soloChartVersion,
config.valuesArg)
}
Expand Down Expand Up @@ -508,7 +508,7 @@ export class NetworkCommand extends BaseCommand {
await this.chartManager.upgrade(
config.namespace,
constants.SOLO_DEPLOYMENT_CHART,
config.chartPath,
constants.SOLO_TESTING_CHART_URL + constants.SOLO_DEPLOYMENT_CHART,
config.valuesArg,
config.soloChartVersion
)
Expand Down
3 changes: 1 addition & 2 deletions src/commands/node/tasks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1128,8 +1128,7 @@ export class NodeCommandTasks {

await this.chartManager.upgrade(
config.namespace,
constants.SOLO_DEPLOYMENT_CHART,
config.chartPath,
constants.SOLO_DEPLOYMENT_CHART, constants.SOLO_TESTING_CHART_URL + constants.SOLO_DEPLOYMENT_CHART,
valuesArg,
config.soloChartVersion
)
Expand Down
3 changes: 1 addition & 2 deletions src/core/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ export const HEDERA_NODE_DEFAULT_STAKE_AMOUNT = +process.env.SOLO_NODE_DEFAULT_S

// --------------- Charts related constants ----------------------------------------------------------------------------
export const SOLO_SETUP_NAMESPACE = 'solo-setup'
export const SOLO_TESTING_CHART_URL = 'https://hashgraph.github.io/solo-charts/charts'
export const SOLO_TESTING_CHART_URL = 'oci://ghcr.io/hashgraph/solo-charts/'
export const SOLO_TESTING_CHART = 'solo-charts'
export const SOLO_CLUSTER_SETUP_CHART = 'solo-cluster-setup'
export const SOLO_DEPLOYMENT_CHART = 'solo-deployment'
Expand All @@ -65,7 +65,6 @@ export const HEDERA_EXPLORER_CHART_UTL = 'oci://ghcr.io/hashgraph/hedera-mirror-
export const HEDERA_EXPLORER_CHART = 'hedera-explorer'

export const DEFAULT_CHART_REPO: Map<string, string> = new Map()
.set(SOLO_TESTING_CHART, SOLO_TESTING_CHART_URL)
.set(JSON_RPC_RELAY_CHART, JSON_RPC_RELAY_CHART_URL)
.set(MIRROR_NODE_RELEASE_NAME, MIRROR_NODE_CHART_URL)

Expand Down
3 changes: 2 additions & 1 deletion test/e2e/commands/network.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,8 @@ describe('NetworkCommand', () => {
flags.profileFile.constName,
flags.profileName.constName,
flags.quiet.constName,
flags.settingTxt.constName
flags.settingTxt.constName,
'chartPath'
])
} catch (e) {
networkCmd.logger.showUserError(e)
Expand Down
1 change: 1 addition & 0 deletions test/e2e/commands/separate_node_add.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ e2eTestSuite(namespace, argv, undefined, undefined, undefined, undefined, undefi
flags.devMode.constName,
flags.force.constName,
flags.quiet.constName,
'chartPath',
'curDate',
'freezeAdminPrivateKey'
])
Expand Down
3 changes: 2 additions & 1 deletion test/test_add.ts
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,8 @@ export function testNodeAdd (localBuildPath: string, testDescription = 'Node add
flags.devMode.constName,
flags.force.constName,
flags.quiet.constName,
flags.adminKey.constName
flags.adminKey.constName,
'chartPath'
])
await bootstrapResp.opts.accountManager.close()
}).timeout(12 * MINUTES)
Expand Down
3 changes: 2 additions & 1 deletion test/test_util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,8 @@ export function e2eTestSuite (
flags.profileFile.constName,
flags.profileName.constName,
flags.quiet.constName,
flags.settingTxt.constName
flags.settingTxt.constName,
'chartPath'
])
}).timeout(3 * MINUTES)

Expand Down
2 changes: 1 addition & 1 deletion version.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

export const JAVA_VERSION = '21.0.1+12'
export const HELM_VERSION = 'v3.14.2'
export const SOLO_CHART_VERSION = 'v0.33.0'
export const SOLO_CHART_VERSION = '0.34.0'
export const HEDERA_PLATFORM_VERSION = 'v0.54.0-alpha.4'
export const MIRROR_NODE_VERSION = '0.116.0'
export const HEDERA_EXPLORER_VERSION = '0.2.1'

0 comments on commit 1973275

Please sign in to comment.