UNPKG

@hashgraph/solo

Version:

An opinionated CLI tool to deploy and manage private Hedera Networks.

41 lines 1.45 kB
// SPDX-License-Identifier: Apache-2.0 import { InstallChartOptionsBuilder } from '../../model/install/install-chart-options-builder.js'; /** * A request to install a Helm chart. */ export class ChartInstallRequest { releaseName; chart; options; /** * Creates a new install request with the given chart and options. * * @param releaseName The name of the release. * @param chart The chart to install. * @param options The options to use when installing the chart. */ constructor(releaseName, chart, options = InstallChartOptionsBuilder.builder().build()) { this.releaseName = releaseName; this.chart = chart; this.options = options; if (!releaseName) { throw new Error('releaseName must not be null'); } if (releaseName.trim() === '') { throw new Error('releaseName must not be blank'); } if (!chart) { throw new Error('chart must not be null'); } if (!options) { throw new Error('options must not be null'); } } apply(builder) { builder.subcommands('install'); this.options.apply(builder); const chartName = this.options.repo && this.options.repo !== '' ? this.chart.unqualified() : this.chart.qualified(); builder.positional(this.releaseName).positional(chartName); } } //# sourceMappingURL=chart-install-request.js.map