Fixes networking related constraints for Virtual deployments
[genesis.git] / foreman / ci / Vagrantfile
index 100e12d..a01da70 100644 (file)
@@ -41,6 +41,9 @@ Vagrant.configure(2) do |config|
   default_gw = ""
   nat_flag = false
 
+  # Disable dhcp flag
+  disable_dhcp_flag = false
+
   # Share an additional folder to the guest VM. The first argument is
   # the path on the host to the actual folder. The second argument is
   # the path on the guest to mount the folder. And the optional third
@@ -90,4 +93,8 @@ Vagrant.configure(2) do |config|
     config.vm.provision :shell, path: "nat_setup.sh"
   end
   config.vm.provision :shell, path: "bootstrap.sh"
+  if disable_dhcp_flag
+    config.vm.provision :shell, :inline => "systemctl stop dhcpd"
+    config.vm.provision :shell, :inline => "systemctl disable dhcpd"
+  end
 end