Module: Chef::Sugar::Cloud

Extended by:
Cloud
Included in:
Cloud
Defined in:
lib/chef/sugar/cloud.rb

Instance Method Summary collapse

Instance Method Details

#azure?(node) ⇒ Boolean

Return true if the current current node is in Azure



127
128
129
# File 'lib/chef/sugar/cloud.rb', line 127

def azure?(node)
  node.key?('azure')
end

#cloud?(node) ⇒ Boolean

Return true if the current current node is in “the cloud”.



30
31
32
# File 'lib/chef/sugar/cloud.rb', line 30

def cloud?(node)
  node.key?('cloud')
end

#cloudstack?(node) ⇒ Boolean

Return true if the current current node is in Cloudstack



115
116
117
# File 'lib/chef/sugar/cloud.rb', line 115

def cloudstack?(node)
  node.key?('cloudstack')
end

#digitalocean?(node) ⇒ Boolean

Return true if the current current node is in DigitalOcean



139
140
141
# File 'lib/chef/sugar/cloud.rb', line 139

def digitalocean?(node)
  node.key?('digital_ocean')
end

#ec2?(node) ⇒ Boolean

Return true if the current current node is in EC2



42
43
44
# File 'lib/chef/sugar/cloud.rb', line 42

def ec2?(node)
  node.key?('ec2')
end

#eucalyptus?(node) ⇒ Boolean Also known as: euca?

Return true if the current current node is in Eucalyptus



78
79
80
# File 'lib/chef/sugar/cloud.rb', line 78

def eucalyptus?(node)
  node.key?('eucalyptus')
end

#gce?(node) ⇒ Boolean

Return true if the current current node is in GCE



54
55
56
# File 'lib/chef/sugar/cloud.rb', line 54

def gce?(node)
  node.key?('gce')
end

#linode?(node) ⇒ Boolean

Return true if the current current node is in Linode



91
92
93
# File 'lib/chef/sugar/cloud.rb', line 91

def linode?(node)
  node.key?('linode')
end

#openstack?(node) ⇒ Boolean

Return true if the current current node is in Openstack



103
104
105
# File 'lib/chef/sugar/cloud.rb', line 103

def openstack?(node)
  node.key?('openstack')
end

#rackspace?(node) ⇒ Boolean

Return true if the current current node is in Rackspace



66
67
68
# File 'lib/chef/sugar/cloud.rb', line 66

def rackspace?(node)
  node.key?('rackspace')
end