@leverege/build-tools 2.61.3 → 2.61.4
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
CHANGED
package/src/Utils.mjs
CHANGED
|
@@ -399,6 +399,7 @@ export const getRepositoryDescr = async () => {
|
|
|
399
399
|
const currentDir = process.cwd()
|
|
400
400
|
const workingDir = process.env.PWD
|
|
401
401
|
const gitRoot = await getGitRootDirectory()
|
|
402
|
+
const isGitRepo = gitRoot !== undefined
|
|
402
403
|
const gitHooksPath = await getGitHooksPath()
|
|
403
404
|
const { branch : gitBranch, upstream : gitUpstream } = await getGitBranchAndUpstream()
|
|
404
405
|
const subPkgs = await glob( `${gitRoot}/packages/**/package.json`, { ignore : '/**/node_modules/**' } )
|
|
@@ -420,6 +421,7 @@ export const getRepositoryDescr = async () => {
|
|
|
420
421
|
gitRoot,
|
|
421
422
|
gitUpstream,
|
|
422
423
|
helmChart,
|
|
424
|
+
isGitRepo,
|
|
423
425
|
isMonoRepo,
|
|
424
426
|
isNpmWorkspace,
|
|
425
427
|
rootPackageJson,
|
|
@@ -4,20 +4,23 @@ showInstalling "The Prometheus Operator and Components"
|
|
|
4
4
|
addHelmRepo prometheus-community https://prometheus-community.github.io/helm-charts
|
|
5
5
|
|
|
6
6
|
showInstalling "The Prometheus Operator (kube-prometheus-stack)"
|
|
7
|
-
[ -z "$PROMETHEUS_STACK_CHART_VERSION" ] && PROMETHEUS_STACK_CHART_VERSION="
|
|
7
|
+
[ -z "$PROMETHEUS_STACK_CHART_VERSION" ] && PROMETHEUS_STACK_CHART_VERSION="68"
|
|
8
8
|
|
|
9
9
|
NS="--namespace prometheus"
|
|
10
10
|
|
|
11
|
+
# https://artifacthub.io/packages/helm/prometheus-community/kube-prometheus-stack
|
|
11
12
|
helm upgrade $NS --install prometheus-stack prometheus-community/kube-prometheus-stack \
|
|
12
13
|
--values prom-operator/prometheus-stack.yaml \
|
|
13
14
|
--version $PROMETHEUS_STACK_CHART_VERSION $HELM_WHAT
|
|
14
15
|
|
|
16
|
+
# https://artifacthub.io/packages/helm/prometheus-community/prometheus-elasticsearch-exporter
|
|
15
17
|
showInstalling "The Elasticsearch Exporter (prom-operator)"
|
|
16
18
|
[ -z "$ELASTICSEARCH_EXPORTER_CHART_VERSION" ] && ELASTICSEARCH_EXPORTER_CHART_VERSION="6"
|
|
17
19
|
helm upgrade $NS --install elasticsearch8-exporter prometheus-community/prometheus-elasticsearch-exporter \
|
|
18
20
|
--values prom-operator/elasticsearch-exporter.yaml \
|
|
19
21
|
--version $ELASTICSEARCH_EXPORTER_CHART_VERSION $HELM_WHAT
|
|
20
22
|
|
|
23
|
+
# https://artifacthub.io/packages/helm/prometheus-community/prometheus-stackdriver-exporter
|
|
21
24
|
showInstalling "The Stackdriver Exporter (prom-operator)"
|
|
22
25
|
[ -z "$STACKDRIVER_EXPORTER_CHART_VERSION" ] && STACKDRIVER_EXPORTER_CHART_VERSION="4"
|
|
23
26
|
helm upgrade $NS --install stackdriver-exporter prometheus-community/prometheus-stackdriver-exporter \
|
|
@@ -128,6 +128,15 @@ export default class Config {
|
|
|
128
128
|
|
|
129
129
|
async bootstrapHookAndRelease() {
|
|
130
130
|
const repoDescr = await getRepositoryDescr()
|
|
131
|
+
if ( !repoDescr.isGitRepo ) {
|
|
132
|
+
const notGitRepo = `
|
|
133
|
+
The hook-and-release script only works with git repositories. Try running:
|
|
134
|
+
|
|
135
|
+
git init && hook-and-release --init
|
|
136
|
+
|
|
137
|
+
to initialize git and hook-and-release.`
|
|
138
|
+
errorExit( notGitRepo )
|
|
139
|
+
}
|
|
131
140
|
this.gitRoot = repoDescr.gitRoot
|
|
132
141
|
this.gitBranch = repoDescr.gitBranch
|
|
133
142
|
this.gitHooksPath = repoDescr.gitHooksPath
|