28 lines
771 B
Ruby
28 lines
771 B
Ruby
module VagrantPlugins
|
|
module ProviderVirtualBox
|
|
class Config < Vagrant.plugin("2", :config)
|
|
attr_reader :customizations
|
|
|
|
def initialize
|
|
@customizations = []
|
|
end
|
|
|
|
# Customize the VM by calling `VBoxManage` with the given
|
|
# arguments.
|
|
#
|
|
# When called multiple times, the customizations will be applied
|
|
# in the order given.
|
|
#
|
|
# The special `:name` parameter in the command will be replaced with
|
|
# the unique ID or name of the virtual machine. This is useful for
|
|
# parameters to `modifyvm` and the like.
|
|
#
|
|
# @param [Array] command An array of arguments to pass to
|
|
# VBoxManage.
|
|
def customize(command)
|
|
@customizations << command
|
|
end
|
|
end
|
|
end
|
|
end
|