-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathMakefile
More file actions
44 lines (35 loc) · 1.28 KB
/
Copy pathMakefile
File metadata and controls
44 lines (35 loc) · 1.28 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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
.PHONY: all deps bin-check ansible_deps vagrant-deps clean
BINS := ansible
BINS += vagrant
BINS += terraform
all: deps
bin-check:
@for i in $(BINS); do \
if ! which $$i 2>&1 > /dev/null ; then \
echo "--------------------------------------------- ";\
echo "$$i not installed, install it. In the ";\
echo "future we may have an option to try to do this";\
echo "for you... but for now, its on you to do this.";\
echo "--------------------------------------------- ";\
return 1 ;\
else \
echo "$$i installed !" ;\
fi \
done
terraform-deps:
@ansible-playbook -i hosts playbooks/kdevops_terraform.yml
@if [ -d terraform ]; then \
make -C terraform deps; \
fi
vagrant-deps:
@ansible-playbook -i hosts playbooks/kdevops_vagrant.yml
ansible_deps:
@ansible-galaxy install -r requirements.yml
deps: bin-check ansible_deps terraform-deps vagrant-deps
@echo Installed dependencies
terraform-clean:
@if [ -d terraform ]; then \
make -C terraform clean ; \
fi
clean: terraform-clean
@echo Cleaned up