Vagrant.configure("2") do |config|
  config.vm.box = "generic/ubuntu2404"
  config.vm.hostname = "ubuntu2404"
  config.trigger.before [:up, :destroy] do |trigger|
    trigger.run = {inline: "bash -c 'lsmod | grep -q tun || sudo modprobe tun'"}
  end
  config.vm.provider :libvirt do |libvirt|
    libvirt.storage_pool_path = "/data/libvirt"
    libvirt.management_network_mac = "52:54:00:00:24:04"
  end
  config.vm.synced_folder "./", "/vagrant", type: "sshfs"
end