Method: Fog::OpenStack::Compute::Volume#attach

Defined in:
lib/fog/openstack/compute/models/volume.rb

#attach(server_id, name) ⇒ Object



33
34
35
36
37
38
# File 'lib/fog/openstack/compute/models/volume.rb', line 33

def attach(server_id, name)
  requires :id
  data = service.attach_volume(id, server_id, name)
  merge_attributes(:attachments => attachments << data.body['volumeAttachment'])
  true
end