From 956a160a62cf2f4f7208b8b02c42738788bdcf66 Mon Sep 17 00:00:00 2001 From: Carlos de Paula Date: Mon, 22 Jun 2020 14:07:18 -0300 Subject: [PATCH] Add Docker Makefile target With this change, the manifests are built in a Docker container without the need to install the pre-reqs like Golang, Jsonnet and etc. --- Makefile | 3 +++ Readme.md | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 663b6fa..ea23bc0 100644 --- a/Makefile +++ b/Makefile @@ -18,6 +18,9 @@ manifests: $(JSONNET_BIN) ## Builds the manifests rm -rf manifests ./scripts/build.sh main.jsonnet $(JSONNET_BIN) +docker: ## Builds the manifests in a Docker container to avoid installing pre-requisites (Golang, Jsonnet, etc) + docker run -it --rm -v $(PWD):/work -w /work --rm golang make vendor && make + update_libs: $(JB_BINARY) ## Updates vendor libs. Require a regeneration of the manifests $(JB_BINARY) update diff --git a/Readme.md b/Readme.md index a7ec134..a8860b1 100644 --- a/Readme.md +++ b/Readme.md @@ -38,7 +38,7 @@ The ingresses can use TLS with the default self-signed certificate from your Ing Persistence for Prometheus and Grafana can be enabled in the `enablePersistence` section. Setting each to `true`, creates the volume PVCs. If no PV names are defined in `prometheusPV` and `grafanaPV`, the default StorageClass will be used to dynamically create the PVs The sizes can be adjusted in `prometheusSizePV` and `grafanaSizePV`. -Changing these parameters require a rebuild of the manifests with `make` followed by `make deploy`. +Changing these parameters require a rebuild of the manifests with `make` followed by `make deploy`. To avoid installing all pre-requisites like Golang, Jsonnet, Jsonnet-bundler, use the target `make docker` to build in a container. ## Quickstart (non K3s)