summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSachin Prabhu <sprabhu@redhat.com>2021-04-14 18:34:49 +0100
committerGünther Deschner <gd@samba.org>2021-04-16 14:43:53 +0200
commit04faa3494e8aa594cde138e2f9b2ef3ee064f2c6 (patch)
tree441e0d845c60430b84ba085c28b07bca269327c1
parent522e1eb666332b4dd8f1b7d6d3e25a670eee1839 (diff)
downloadsamba-integration-04faa3494e8aa594cde138e2f9b2ef3ee064f2c6.tar.gz
samba-integration-04faa3494e8aa594cde138e2f9b2ef3ee064f2c6.tar.xz
samba-integration-04faa3494e8aa594cde138e2f9b2ef3ee064f2c6.zip
Add make clean to Makefile
Allow users to remove temporary files with make clean Signed-off-by: Sachin Prabhu <sprabhu@redhat.com>
-rw-r--r--Makefile3
-rw-r--r--vagrant/Makefile10
2 files changed, 13 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 02a6dc2..40b0879 100644
--- a/Makefile
+++ b/Makefile
@@ -1,3 +1,6 @@
.PHONY: test
test:
@$(MAKE) -C vagrant setup.site
+
+clean:
+ @$(MAKE) -C vagrant clean
diff --git a/vagrant/Makefile b/vagrant/Makefile
index 1702e4d..cfcbb6d 100644
--- a/vagrant/Makefile
+++ b/vagrant/Makefile
@@ -1,5 +1,6 @@
INVENTORY := ./vagrant_ansible_inventory
VSSH := ssh -F ssh-config-host
+VAGRANT := vagrant
ifdef EXTRA_VARS
ANSIBLE_EXTRA_VARS := -e '${EXTRA_VARS}'
@@ -39,4 +40,13 @@ setup.site: setup.cluster setup.clients client.test
client1.test:
@$(VSSH) client1 "sudo make -C /root/samba-integration-tests test"
+clean_vagrant:
+ @$(VAGRANT) destroy -f
+ @rm -rf .vagrant
+
+clean_generated_files:
+ @rm -f Vagrantfile ansible/distro-vars.yml ansible/vagrant_ansible_inventory ansible/ssh-config-setup vagrant_ansible_inventory ssh-config-host
+
+clean: clean_generated_files clean_vagrant
+
.PHONY: local hosts.update.only setup.prep.only setup.prep setup.test.only setup.cluster.only setup.cluster setup.clients client.test setup.site client1.test