Class: VagrantAWS::Box

Inherits:
Vagrant::Box
  • Object
show all
Defined in:
lib/vagrant-aws/box.rb

Instance Method Summary collapse

Instance Method Details

#addObject

Raises:

  • (Vagrant::Errors::BoxAlreadyExists)


9
10
11
12
# File 'lib/vagrant-aws/box.rb', line 9

def add
	raise Vagrant::Errors::BoxAlreadyExists, :name => name if File.directory?(directory)
	env.actions.run(:aws_add_image, { "box" => self, "validate" => false })
end

#remove(options = nil) ⇒ Object



14
15
16
# File 'lib/vagrant-aws/box.rb', line 14

def remove(options=nil)
	env.actions.run(:aws_remove_image, { "box" => self, "validate" => false }.merge(options || {}))
end