This commit is a continuation of the work that cclerget started. This change includes the following updates: - Fixes blocking issues preventing vagrant-libvirt from working in my test environments. - Overhauls the README documentation to add system setup instructions and troubleshooting information.
41 lines
901 B
Plaintext
41 lines
901 B
Plaintext
class InitWarewulf < Vagrant.plugin(2, :command)
|
|
def self.synopsis
|
|
"Initialize Warewulf Dev Environment"
|
|
end
|
|
|
|
def execute
|
|
system "vagrant up"
|
|
system "vagrant provision --provision-with provision-vbmc wwctl"
|
|
system "vagrant provision --provision-with add-ww-nodes wwctl"
|
|
end
|
|
end
|
|
|
|
class CleanupWarewulf < Vagrant.plugin(2, :command)
|
|
def self.synopsis
|
|
"Cleanup Warewulf Dev Environment"
|
|
end
|
|
|
|
def execute
|
|
system "vagrant ssh wwctl -c 'sudo wwctl power off n1' || true"
|
|
system "vagrant ssh wwctl -c 'sudo wwctl power off n2' || true"
|
|
system "vagrant halt"
|
|
system "vagrant destroy -f"
|
|
end
|
|
end
|
|
|
|
class InitWarewulfPlugin < Vagrant.plugin(2)
|
|
name "InitWarewulf"
|
|
|
|
command "init-warewulf" do
|
|
InitWarewulf
|
|
end
|
|
end
|
|
|
|
class CleanupWarewulfPlugin < Vagrant.plugin(2)
|
|
name "CleanupWarewulf"
|
|
|
|
command "cleanup-warewulf" do
|
|
CleanupWarewulf
|
|
end
|
|
end
|