2012-04-19 04:23:25 +00:00
|
|
|
require "vagrant"
|
|
|
|
|
|
|
|
module VagrantPlugins
|
|
|
|
module GuestRedHat
|
2012-11-07 05:14:45 +00:00
|
|
|
class Plugin < Vagrant.plugin("2")
|
2015-05-19 10:58:19 +00:00
|
|
|
name "Red Hat Enterprise Linux guest"
|
|
|
|
description "Red Hat Enterprise Linux guest support."
|
2012-04-19 04:23:25 +00:00
|
|
|
|
2013-04-04 04:47:57 +00:00
|
|
|
guest("redhat", "linux") do
|
2012-05-23 22:57:43 +00:00
|
|
|
require File.expand_path("../guest", __FILE__)
|
|
|
|
Guest
|
|
|
|
end
|
2013-04-04 19:09:40 +00:00
|
|
|
|
|
|
|
guest_capability("redhat", "change_host_name") do
|
|
|
|
require_relative "cap/change_host_name"
|
|
|
|
Cap::ChangeHostName
|
|
|
|
end
|
|
|
|
|
|
|
|
guest_capability("redhat", "configure_networks") do
|
|
|
|
require_relative "cap/configure_networks"
|
|
|
|
Cap::ConfigureNetworks
|
|
|
|
end
|
|
|
|
|
2014-08-31 05:44:48 +00:00
|
|
|
guest_capability("redhat", "flavor") do
|
|
|
|
require_relative "cap/flavor"
|
|
|
|
Cap::Flavor
|
|
|
|
end
|
|
|
|
|
2013-04-04 19:09:40 +00:00
|
|
|
guest_capability("redhat", "network_scripts_dir") do
|
|
|
|
require_relative "cap/network_scripts_dir"
|
|
|
|
Cap::NetworkScriptsDir
|
|
|
|
end
|
2014-01-10 00:58:20 +00:00
|
|
|
|
2014-01-16 02:37:02 +00:00
|
|
|
guest_capability("redhat", "nfs_client_install") do
|
2014-01-10 00:58:20 +00:00
|
|
|
require_relative "cap/nfs_client"
|
|
|
|
Cap::NFSClient
|
|
|
|
end
|
2014-01-31 03:26:43 +00:00
|
|
|
|
2015-06-30 08:21:58 +00:00
|
|
|
guest_capability("redhat", "nfs_client_installed") do
|
|
|
|
require_relative "cap/nfs_client"
|
|
|
|
Cap::NFSClient
|
|
|
|
end
|
|
|
|
|
2014-01-31 03:26:43 +00:00
|
|
|
guest_capability("redhat", "rsync_install") do
|
|
|
|
require_relative "cap/rsync"
|
|
|
|
Cap::RSync
|
|
|
|
end
|
2015-09-20 07:30:49 +00:00
|
|
|
|
|
|
|
def self.dnf?(machine)
|
|
|
|
machine.communicate.test("/usr/bin/which -s dnf")
|
|
|
|
end
|
2012-04-19 04:23:25 +00:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|