@leverege/build-tools 2.86.0-beta.1 → 2.86.0-beta.3
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/package.json +1 -1
- package/src/Utils.mjs +2 -2
- package/src/docker-to-registry.mjs +4 -6
package/package.json
CHANGED
package/src/Utils.mjs
CHANGED
|
@@ -580,7 +580,7 @@ export const analyzeRepository = async ( giveGuidance ) => {
|
|
|
580
580
|
const artifactProject = closestPackageJson?.artifactRegistry.project || rootPyProjectToml?.artifactRegistry.project || 'unknown'
|
|
581
581
|
const packageVersion = `v${closestPackageJson?.version || rootPyProjectToml?.project.version}`
|
|
582
582
|
const generateDockerfile = ( closestPackageJson?.leverege.generateDockerfile || rootPyProjectToml?.leverege['generate-dockerfile'] ) ?? true
|
|
583
|
-
const
|
|
583
|
+
const requiresHelmChart = ( closestPackageJson?.leverege.requiresHelmChart || rootPyProjectToml?.leverege['requires-helm-chart'] ) ?? true
|
|
584
584
|
|
|
585
585
|
const currentDir = process.cwd()
|
|
586
586
|
const closestPkg = await packageUp()
|
|
@@ -603,7 +603,7 @@ export const analyzeRepository = async ( giveGuidance ) => {
|
|
|
603
603
|
artifactProject,
|
|
604
604
|
artifactRegistry,
|
|
605
605
|
buildToolsVersion,
|
|
606
|
-
|
|
606
|
+
requiresHelmChart,
|
|
607
607
|
containerName,
|
|
608
608
|
imagePlatform,
|
|
609
609
|
currentDir,
|
|
@@ -90,7 +90,7 @@ if ( semver.lt( semver.coerce( repoDescr.buildToolsVersion ), minimumBuildToolsV
|
|
|
90
90
|
const {
|
|
91
91
|
artifactProject,
|
|
92
92
|
artifactRegistry,
|
|
93
|
-
|
|
93
|
+
requiresHelmChart,
|
|
94
94
|
packageVersion,
|
|
95
95
|
containerName,
|
|
96
96
|
imagePlatform,
|
|
@@ -101,9 +101,7 @@ const {
|
|
|
101
101
|
isPythonProject,
|
|
102
102
|
} = repoDescr
|
|
103
103
|
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
if ( deploymentTargetIncludesK8s ) {
|
|
104
|
+
if ( requiresHelmChart ) {
|
|
107
105
|
if ( !fs.existsSync( './helm' ) ) {
|
|
108
106
|
log( `
|
|
109
107
|
${chalk.red.bold( '***Error: docker-to-registry requires a helm chart directory' )}
|
|
@@ -204,7 +202,7 @@ if ( giveGuidance ) {
|
|
|
204
202
|
|
|
205
203
|
// do chart checks too
|
|
206
204
|
let chart
|
|
207
|
-
if (
|
|
205
|
+
if ( requiresHelmChart && options?.helmChecks !== 'false' ) {
|
|
208
206
|
chart = helmChart?.yaml['Chart.yaml']
|
|
209
207
|
const values = helmChart?.yaml['values.yaml']
|
|
210
208
|
const expectedChartRegistry = `${artifactRegistry}/images`
|
|
@@ -311,7 +309,7 @@ if ( willGitTag && !repoInfo.upstream ) {
|
|
|
311
309
|
}
|
|
312
310
|
|
|
313
311
|
if ( willGitTag ) {
|
|
314
|
-
if (
|
|
312
|
+
if ( requiresHelmChart ) {
|
|
315
313
|
if ( chart.appVersion !== imageVersion ) {
|
|
316
314
|
log( `
|
|
317
315
|
${chalk.yellow.bold( '***WARNING: the helm/Chart.yaml appVersion does not align with the build version' )}
|