-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
28 lines (21 loc) · 1.2 KB
/
Makefile
File metadata and controls
28 lines (21 loc) · 1.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
OSName = $(shell uname -o)
JSONNETS = $(wildcard *.jsonnet)
YAMLS = $(wildcard *.yaml)
JSONS = $(patsubst %.yaml,%.json,$(filter-out webrtc.yaml, $(YAMLS)))
all: ${JSONS}
clean:
rm -rf ${JSONS}
ifeq (${ETCDPASS},)
ETCDAUTH =
else
ETCDAUTH = --user root --password "${ETCDPASS}"
endif
$(JSONS): %.json: %.yaml $(JSONNETS)
#jsonnet --ext-str CID=${CID} --ext-str-file confYaml=$< main.jsonnet --ext-str OSName=${OSName} --ext-str deploy=systemd -o $@
jsonnet --ext-str CID=s26 --ext-str-file confYaml=sample-nvr.yaml main.jsonnet --ext-str OSName=${OSName} --ext-str deploy=systemd -o sample-nvr.json
jsonnet --ext-str CID=${CID} --ext-str-file confYaml=sample-conntour-poc.yaml --ext-str-file webrtcOverrides=webrtc.yaml main-conntour.jsonnet --ext-str OSName=${OSName} --ext-str deploy=docker -o sample-conntour-poc.json
jsonnet --ext-str CID=a50 --ext-str-file confYaml=sample-acp-uz.yaml main-acp-uz.jsonnet --ext-str OSName=${OSName} --ext-str deploy=systemd --ext-str-file def=acp-uz-defaults.yaml -o sample-acp-uz.json
etcdclean:
etcdctl del ${ETCD_PREFIX}/templates --prefix $(ETCDAUTH)
etcdupload:
for i in ${JSONNETS}; do etcdctl put ${ETCD_PREFIX}/templates/jsonnet/$${i} $(ETCDAUTH) < $${i}; done