This commit is contained in:
2020-02-19 20:26:02 -08:00
parent 82e65ed42a
commit 1b7944a174
7 changed files with 474 additions and 4 deletions

View File

@@ -0,0 +1,29 @@
export VMNAME := ubuntu1804
export DISK_DIR := /storage/scratch/tmp
export HOST := las1.local
.PHONY: clean install reinstall rcopy rrun
default: remote
clean:
-virsh destroy $(VMNAME)
-virsh undefine $(VMNAME)
rm -f $(DISK_DIR)/$(VMNAME).qcow2
install:
bash install.sh
reinstall: clean install
remote: rrun
rcopy:
rsync -avP ./ root@$(HOST):/storage/admin/vms/
rrun: rcopy
ssh -t root@$(HOST) "cd /storage/admin/vms && make reinstall"
rclean: rcopy
ssh -t root@$(HOST) "cd /storage/admin/vms && make clean"