-
Notifications
You must be signed in to change notification settings - Fork 3
/
Makefile
48 lines (36 loc) · 1.42 KB
/
Makefile
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
KUSTOMIZE = bin/kustomize build --load-restrictor LoadRestrictionsNone --enable-alpha-plugins
JITSI_K8S_ENV ?= default
# -- Docker
# Get the current user ID to use for docker run and docker exec commands
DOCKER_UID = $(shell id -u)
DOCKER_GID = $(shell id -g)
DOCKER_USER = $(DOCKER_UID):$(DOCKER_GID)
COMPOSE = DOCKER_USER=$(DOCKER_USER) docker-compose
default: help
build: ## build the app container
@$(COMPOSE) build app
.PHONY: build
bootstrap: ## Bootstrap the jitsi-k8s project
bootstrap: \
env.d/kustomize \
env.d/simulation \
env.d/terraform
env.d/terraform:
cp env.d/terraform.dist env.d/terraform
env.d/kustomize:
cp env.d/kustomize.dist env.d/kustomize
env.d/simulation:
cp env.d/simulation.dist env.d/simulation
k8s-apply-config: ## Build and deploy the Kubernetes configuration for jitsi
@$(KUSTOMIZE) /data/k8s/overlays/$(JITSI_K8S_ENV) > k8s/.k8s-built-config
bin/kubectl apply -f /data/k8s/.k8s-built-config
.PHONY: k8s-apply-config
k8s-build-config: ## Build and display the Kubernetes configuration for jitsi
@$(KUSTOMIZE) /data/k8s/overlays/$(JITSI_K8S_ENV)
.PHONY: k8s-build-config
simulation: ## Simulate the functioning of the HPA on the JVB ReplicaSet
python3 docs/simulations/jvb_hpa.py
.PHONY: simulation
help:
@grep -E '^[a-zA-Z0-9_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
.PHONY: help