mirror of
https://github.com/trustgraph-ai/trustgraph.git
synced 2026-07-17 09:11:03 +02:00
Reworked templater to produce docker compose and minikube output
This commit is contained in:
parent
19625d1cde
commit
713d903293
59 changed files with 37925 additions and 7034 deletions
38
Makefile
38
Makefile
|
|
@ -1,6 +1,6 @@
|
|||
|
||||
# VERSION=$(shell git describe | sed 's/^v//')
|
||||
VERSION=0.9.3
|
||||
VERSION=0.10.0
|
||||
|
||||
DOCKER=podman
|
||||
|
||||
|
|
@ -50,23 +50,45 @@ VECTORDB=qdrant
|
|||
JSONNET_FLAGS=-J templates -J .
|
||||
|
||||
|
||||
update-templates: set-version
|
||||
update-templates: update-dcs update-minikubes
|
||||
|
||||
JSON_TO_YAML=python3 -c 'import sys, yaml, json; j=json.loads(sys.stdin.read()); print(yaml.safe_dump(j))'
|
||||
# JSON_TO_YAML=cat
|
||||
|
||||
update-dcs: set-version
|
||||
rm -rf deploy
|
||||
mkdir -p deploy/docker-compose deploy/minikube
|
||||
for graph in ${GRAPHS}; do \
|
||||
cm=$${graph},pulsar,${VECTORDB},grafana; \
|
||||
input=templates/main.jsonnet; \
|
||||
output=tg-storage-$${graph}.yaml; \
|
||||
input=templates/opts-to-docker-compose.jsonnet; \
|
||||
output=deploy/docker-compose/tg-storage-$${graph}.yaml; \
|
||||
echo $${graph} '->' $${output}; \
|
||||
jsonnet ${JSONNET_FLAGS} \
|
||||
--ext-str options=$${cm} -S $${input} > $${output}; \
|
||||
--ext-str options=$${cm} $${input} | \
|
||||
${JSON_TO_YAML} > $${output}; \
|
||||
done
|
||||
for model in ${MODELS}; do \
|
||||
for graph in ${GRAPHS}; do \
|
||||
cm=$${graph},pulsar,${VECTORDB},embeddings-hf,graph-rag,grafana,trustgraph,$${model}; \
|
||||
input=templates/main.jsonnet; \
|
||||
output=tg-launch-$${model}-$${graph}.yaml; \
|
||||
input=templates/opts-to-docker-compose.jsonnet; \
|
||||
output=deploy/docker-compose/tg-launch-$${model}-$${graph}.yaml; \
|
||||
echo $${model} + $${graph} '->' $${output}; \
|
||||
jsonnet ${JSONNET_FLAGS} \
|
||||
--ext-str options=$${cm} -S $${input} > $${output}; \
|
||||
--ext-str options=$${cm} $${input} | \
|
||||
${JSON_TO_YAML} > $${output}; \
|
||||
done; \
|
||||
done
|
||||
|
||||
update-minikubes: set-version
|
||||
for model in ${MODELS}; do \
|
||||
for graph in ${GRAPHS}; do \
|
||||
cm=$${graph},pulsar,${VECTORDB},embeddings-hf,graph-rag,grafana,trustgraph,$${model}; \
|
||||
input=templates/opts-to-minikube-k8s.jsonnet; \
|
||||
output=deploy/minikube/tg-launch-$${model}-$${graph}.yaml; \
|
||||
echo $${model} + $${graph} '->' $${output}; \
|
||||
jsonnet ${JSONNET_FLAGS} \
|
||||
--ext-str options=$${cm} $${input} | \
|
||||
${JSON_TO_YAML} > $${output}; \
|
||||
done; \
|
||||
done
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue