awsome 0.0.8 → 0.0.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/lib/awsome/ec2.rb CHANGED
@@ -111,13 +111,13 @@ module Awsome
111
111
  Awsome.execute(cmd, columns: @@describe_attachments_fields, filter: /^ATTACHMENT/)
112
112
  end
113
113
 
114
- def self.detach_volume(volume_id, device, preumount)
114
+ def self.detach_volume(volume_id, dir, preumount)
115
115
  attachments = describe_attachments('volume-id' => volume_id)
116
116
  if attachments.any?
117
117
  instance_id = attachments.first['instance_id']
118
118
  instance = describe_instances('instance-id' => instance_id).first
119
119
  instance.ssh preumount if preumount
120
- instance.ssh "sudo umount #{device}"
120
+ instance.ssh "sudo umount #{dir}"
121
121
 
122
122
  cmd = Awsome::Ec2.command('ec2-detach-volume', volume_id)
123
123
  Awsome.execute(cmd)
@@ -35,7 +35,7 @@ module Awsome
35
35
 
36
36
  def reattach_volumes(*volumes)
37
37
  volumes.each do |info|
38
- Awsome::Ec2.detach_volume(info['id'], info['device'], info['preumount'])
38
+ Awsome::Ec2.detach_volume(info['id'], info['dir'], info['preumount'])
39
39
  Awsome.wait_until(interval: 10) { Awsome::Ec2.volume_available?(info['id']) }
40
40
  Awsome::Ec2.attach_volume(info['id'], @properties['instance_id'], info['device'])
41
41
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: awsome
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.8
4
+ version: 0.0.9
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: