|
2 | 2 | TESTENVVAR =
|
3 | 3 | REGISTRY ?= gcr.io/k8s-staging-kube-state-metrics
|
4 | 4 | TAG_PREFIX = v
|
5 |
| -VERSION = $(shell cat VERSION) |
| 5 | +VERSION = $(shell gomplate -d config=./data.yaml --in '{{ (datasource "config").version }}') |
6 | 6 | TAG ?= $(TAG_PREFIX)$(VERSION)
|
7 |
| -LATEST_RELEASE_BRANCH := release-$(shell grep -ohE "[0-9]+.[0-9]+" VERSION) |
| 7 | +LATEST_RELEASE_BRANCH := release-$(shell echo $(VERSION) | grep -ohE "[0-9]+.[0-9]+") |
8 | 8 | BRANCH = $(strip $(shell git rev-parse --abbrev-ref HEAD))
|
9 | 9 | DOCKER_CLI ?= docker
|
10 | 10 | PROMTOOL_CLI ?= promtool
|
@@ -151,17 +151,17 @@ examples/prometheus-alerting-rules/alerts.yaml: jsonnet $(shell find jsonnet | g
|
151 | 151 |
|
152 | 152 | examples: examples/standard examples/autosharding examples/daemonsetsharding mixin
|
153 | 153 |
|
154 |
| -examples/standard: jsonnet $(shell find jsonnet | grep ".libsonnet") scripts/standard.jsonnet scripts/vendor VERSION |
| 154 | +examples/standard: jsonnet $(shell find jsonnet | grep ".libsonnet") scripts/standard.jsonnet scripts/vendor |
155 | 155 | mkdir -p examples/standard
|
156 | 156 | jsonnet -J scripts/vendor -m examples/standard --ext-str version="$(VERSION)" scripts/standard.jsonnet | xargs -I{} sh -c 'cat {} | gojsontoyaml > `echo {} | sed "s/\(.\)\([A-Z]\)/\1-\2/g" | tr "[:upper:]" "[:lower:]"`.yaml' -- {}
|
157 | 157 | find examples -type f ! -name '*.yaml' -delete
|
158 | 158 |
|
159 |
| -examples/autosharding: jsonnet $(shell find jsonnet | grep ".libsonnet") scripts/autosharding.jsonnet scripts/vendor VERSION |
| 159 | +examples/autosharding: jsonnet $(shell find jsonnet | grep ".libsonnet") scripts/autosharding.jsonnet scripts/vendor |
160 | 160 | mkdir -p examples/autosharding
|
161 | 161 | jsonnet -J scripts/vendor -m examples/autosharding --ext-str version="$(VERSION)" scripts/autosharding.jsonnet | xargs -I{} sh -c 'cat {} | gojsontoyaml > `echo {} | sed "s/\(.\)\([A-Z]\)/\1-\2/g" | tr "[:upper:]" "[:lower:]"`.yaml' -- {}
|
162 | 162 | find examples -type f ! -name '*.yaml' -delete
|
163 | 163 |
|
164 |
| -examples/daemonsetsharding: jsonnet $(shell find jsonnet | grep ".libsonnet") scripts/daemonsetsharding.jsonnet scripts/vendor VERSION |
| 164 | +examples/daemonsetsharding: jsonnet $(shell find jsonnet | grep ".libsonnet") scripts/daemonsetsharding.jsonnet scripts/vendor |
165 | 165 | mkdir -p examples/daemonsetsharding
|
166 | 166 | jsonnet -J scripts/vendor -m examples/daemonsetsharding --ext-str version="$(VERSION)" scripts/daemonsetsharding.jsonnet | xargs -I{} sh -c 'cat {} | gojsontoyaml > `echo {} | sed "s/\(.\)\([A-Z]\)/\1-\2/g" | tr "[:upper:]" "[:lower:]"`.yaml' -- {}
|
167 | 167 | find examples -type f ! -name '*.yaml' -delete
|
|
0 commit comments