-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
38 lines (23 loc) · 812 Bytes
/
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
.PHONY: build k8s join debug join upgrade status reset
ANSIBLE_INVENTORY := hosts
export ANSIBLE_INVENTORY
ANSIBLE_PLAYBOOK := site.yml
export ANSIBLE_PLAYBOOK
ANSIBLE_CMD := ansible-playbook -i $(ANSIBLE_INVENTORY)
debug: ANSIBLE_DEBUG := -v
debug: build
build:
@$(ANSIBLE_CMD) $(ANSIBLE_PLAYBOOK) $(ANSIBLE_DEBUG)
setup:
@$(ANSIBLE_CMD) $(ANSIBLE_PLAYBOOK) $(ANSIBLE_DEBUG) --tags "setup"
k8s:
@$(ANSIBLE_CMD) $(ANSIBLE_PLAYBOOK) $(ANSIBLE_DEBUG) --tags "k8s"
join:
@$(ANSIBLE_CMD) $(ANSIBLE_PLAYBOOK) $(ANSIBLE_DEBUG) --tags "join"
upgrade:
@$(ANSIBLE_CMD) $(ANSIBLE_PLAYBOOK) $(ANSIBLE_DEBUG) --tags "upgrade"
status:
@$(ANSIBLE_CMD) $(ANSIBLE_PLAYBOOK) $(ANSIBLE_DEBUG) --tags "status"
reset: ANSIBLE_PLAYBOOK := reset.yml
reset:
@$(ANSIBLE_CMD) $(ANSIBLE_PLAYBOOK) $(ANSIBLE_DEBUG)