Sha256: 3b33079a5030df170aafb05a29d2c7886811dacaa2c2a3a68c8e14ee277a4214

Contents?: true

Size: 557 Bytes

Versions: 36

Compression:

Stored size: 557 Bytes

Contents

module VagrantPlugins
  module GuestRedHat
    module Cap
      class Flavor
        def self.flavor(machine)
          # Read the version file
          output = ""
          machine.communicate.sudo("cat /etc/redhat-release") do |_, data|
            output = data
          end

          # Detect various flavors we care about
          if output =~ /(CentOS|Red Hat Enterprise|Scientific|Cloud|Virtuozzo)\s*Linux( .+)? release 7/i
            return :rhel_7
          else
            return :rhel
          end
        end
      end
    end
  end
end

Version data entries

36 entries across 32 versions & 4 rubygems

Version Path
vagrant-unbundled-2.2.7.0 plugins/guests/redhat/cap/flavor.rb
vagrant-unbundled-2.2.6.2 plugins/guests/redhat/cap/flavor.rb
vagrant-unbundled-2.2.6.1 plugins/guests/redhat/cap/flavor.rb
vagrant-unbundled-2.2.6.0 plugins/guests/redhat/cap/flavor.rb
vagrant-unbundled-2.2.5.0 plugins/guests/redhat/cap/flavor.rb
vagrant-unbundled-2.2.4.0 plugins/guests/redhat/cap/flavor.rb
vagrant-unbundled-2.2.3.0 plugins/guests/redhat/cap/flavor.rb
vagrant-unbundled-2.2.2.0 plugins/guests/redhat/cap/flavor.rb
vagrant-unbundled-2.2.0.0 plugins/guests/redhat/cap/flavor.rb
vagrant-unbundled-2.1.4.0 plugins/guests/redhat/cap/flavor.rb
vagrant-unbundled-2.1.2.0 plugins/guests/redhat/cap/flavor.rb
vagrant-packet-0.1.2 vendor/bundle/ruby/2.5.0/bundler/gems/vagrant-04f7215b5e3f/plugins/guests/redhat/cap/flavor.rb
vagrant-packet-0.1.2 vendor/bundle/ruby/2.3.0/bundler/gems/vagrant-04f7215b5e3f/plugins/guests/redhat/cap/flavor.rb
vagrant-packet-0.1.2 vendor/bundle/ruby/2.4.0/bundler/gems/vagrant-04f7215b5e3f/plugins/guests/redhat/cap/flavor.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.3.0/bundler/gems/vagrant-04f7215b5e3f/plugins/guests/redhat/cap/flavor.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.5.0/bundler/gems/vagrant-04f7215b5e3f/plugins/guests/redhat/cap/flavor.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.4.0/bundler/gems/vagrant-04f7215b5e3f/plugins/guests/redhat/cap/flavor.rb
vagrant-unbundled-2.1.1.0 plugins/guests/redhat/cap/flavor.rb
vagrant-unbundled-2.0.4.0 plugins/guests/redhat/cap/flavor.rb
vagrant-unbundled-2.0.3.0 plugins/guests/redhat/cap/flavor.rb