@leverege/build-tools 2.47.2 → 2.47.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 +2 -2
- package/src/Utils.mjs +1 -0
- package/src/docker-to-registry.mjs +15 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@leverege/build-tools",
|
|
3
|
-
"version": "2.47.
|
|
3
|
+
"version": "2.47.3",
|
|
4
4
|
"description": "A collection of build / support tools for Leverege developers",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"repository": {
|
|
@@ -61,7 +61,7 @@
|
|
|
61
61
|
"execa": "^8.0.1",
|
|
62
62
|
"glob": "^10.3.10",
|
|
63
63
|
"handlebars": "^4.7.8",
|
|
64
|
-
"inquirer": "^9.2.
|
|
64
|
+
"inquirer": "^9.2.15",
|
|
65
65
|
"js-yaml": "^4.1.0",
|
|
66
66
|
"ms": "^2.1.3",
|
|
67
67
|
"npm-registry-fetch": "^16.1.0",
|
package/src/Utils.mjs
CHANGED
|
@@ -320,6 +320,7 @@ https://console.cloud.google.com/artifacts/browse/leverege-registry?project=leve
|
|
|
320
320
|
|
|
321
321
|
export const parseHelmChart = async ( helmroot = './helm' ) => {
|
|
322
322
|
/* eslint-disable security/detect-non-literal-fs-filename */
|
|
323
|
+
if ( !existsSync( helmroot ) ) { return undefined }
|
|
323
324
|
const chartFiles = readdirSync( helmroot, { encoding : 'utf8', recursive : true } )
|
|
324
325
|
const chartYaml = YAML.load( readFileSync( `${helmroot}/Chart.yaml`, 'utf8' ) )
|
|
325
326
|
const valuesYaml = YAML.load( readFileSync( `${helmroot}/values.yaml`, 'utf8' ) )
|
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
/*
|
|
3
3
|
* docker-to-registry will...
|
|
4
4
|
*/
|
|
5
|
+
import fs from 'node:fs'
|
|
6
|
+
|
|
5
7
|
import chalk from 'chalk'
|
|
6
8
|
|
|
7
9
|
import {
|
|
@@ -53,6 +55,18 @@ if ( willGitTag && repoIsDirty ) {
|
|
|
53
55
|
process.exit( 1 )
|
|
54
56
|
}
|
|
55
57
|
|
|
58
|
+
if ( !fs.existsSync( './helm' ) ) {
|
|
59
|
+
log( `
|
|
60
|
+
${chalk.red.bold( '***Error: docker-to-registry requires a helm chart directory' )}
|
|
61
|
+
|
|
62
|
+
The docker-to-registry script expects to run in the root directory of a k8s
|
|
63
|
+
service, which requires a helm chart directory. It also expects a docker
|
|
64
|
+
directory but will build that if it does not exist.
|
|
65
|
+
|
|
66
|
+
` )
|
|
67
|
+
process.exit( 1 )
|
|
68
|
+
}
|
|
69
|
+
|
|
56
70
|
const repoDescr = await analyzeRepository()
|
|
57
71
|
debug( { repoDescr }, '<==The Repo Description' )
|
|
58
72
|
|
|
@@ -157,7 +171,7 @@ if ( expectedChartRegistry !== values.image?.registry ) {
|
|
|
157
171
|
its job.
|
|
158
172
|
|
|
159
173
|
` )
|
|
160
|
-
|
|
174
|
+
}
|
|
161
175
|
|
|
162
176
|
process.exit( 1 )
|
|
163
177
|
}
|