Class: Packer::Builder::VirtualBoxISO
Constant Summary
AMAZON_EBS, AMAZON_INSTANCE, DOCKER, NULL, VALID_BUILDER_TYPES, VIRTUALBOX_ISO
Instance Attribute Summary
Attributes inherited from DataObject
#data, #required
Instance Method Summary
collapse
get_builder, #name, types
Methods inherited from DataObject
#__add_array_of_array_of_strings, #__add_array_of_hashes, #__add_array_of_strings, #__add_boolean, #__add_hash, #__add_integer, #__add_string, #__exclusive_key_error, #add_required, #deep_copy, #validate
Constructor Details
Returns a new instance of VirtualBoxISO.
8
9
10
11
12
13
14
15
16
17
|
# File 'lib/packer/builders/virtualbox.rb', line 8
def initialize
super
self.data['type'] = VIRTUALBOX_ISO
self.add_required(
'iso_checksum',
'iso_checksum_type',
'iso_url',
'ssh_username'
)
end
|
Instance Method Details
#boot_command(commands) ⇒ Object
39
40
41
|
# File 'lib/packer/builders/virtualbox.rb', line 39
def boot_command(commands)
self.__add_array_of_strings('boot_command', commands)
end
|
#boot_wait(time) ⇒ Object
43
44
45
|
# File 'lib/packer/builders/virtualbox.rb', line 43
def boot_wait(time)
self.__add_string('boot_wait',time)
end
|
#disk_size(megabytes) ⇒ Object
47
48
49
|
# File 'lib/packer/builders/virtualbox.rb', line 47
def disk_size(megabytes)
self.__add_integer('disk_size', megabytes)
end
|
#export_opts(vboxmanage_export_options) ⇒ Object
51
52
53
|
# File 'lib/packer/builders/virtualbox.rb', line 51
def export_opts(vboxmanage_export_options)
self.__add_array_of_strings('export_opts', vboxmanage_export_options)
end
|
#floppy_files(files) ⇒ Object
55
56
57
|
# File 'lib/packer/builders/virtualbox.rb', line 55
def floppy_files(files)
self.__add_array_of_strings('floppy_files', files)
end
|
59
60
61
|
# File 'lib/packer/builders/virtualbox.rb', line 59
def format(format)
self.__add_string('format', format)
end
|
#guest_additions_mode(mode) ⇒ Object
63
64
65
|
# File 'lib/packer/builders/virtualbox.rb', line 63
def guest_additions_mode(mode)
self.__add_string('guest_additions_mode', mode)
end
|
#guest_additions_path(path) ⇒ Object
67
68
69
|
# File 'lib/packer/builders/virtualbox.rb', line 67
def guest_additions_path(path)
self.__add_string('guest_additions_path', path)
end
|
#guest_additions_sha256(checksum) ⇒ Object
71
72
73
|
# File 'lib/packer/builders/virtualbox.rb', line 71
def guest_additions_sha256(checksum)
self.__add_string('guest_additions_sha256', checksum)
end
|
#guest_additions_url(url) ⇒ Object
75
76
77
|
# File 'lib/packer/builders/virtualbox.rb', line 75
def guest_additions_url(url)
self.__add_string('guest_additions_url', url)
end
|
#guest_os_type(ostype) ⇒ Object
79
80
81
|
# File 'lib/packer/builders/virtualbox.rb', line 79
def guest_os_type(ostype)
self.__add_string('guest_os_type', ostype)
end
|
#hard_drive_interface(controllertype) ⇒ Object
83
84
85
|
# File 'lib/packer/builders/virtualbox.rb', line 83
def hard_drive_interface(controllertype)
self.__add_string('hard_drive_interface', controllertype)
end
|
#headless(bool) ⇒ Object
87
88
89
|
# File 'lib/packer/builders/virtualbox.rb', line 87
def headless(bool)
self.__add_boolean('headless', bool)
end
|
#http_directory(directory) ⇒ Object
91
92
93
|
# File 'lib/packer/builders/virtualbox.rb', line 91
def http_directory(directory)
self.__add_string('http_directory', directory)
end
|
#http_port_max(port_number) ⇒ Object
99
100
101
|
# File 'lib/packer/builders/virtualbox.rb', line 99
def http_port_max(port_number)
self.__add_integer('http_port_max', port_number)
end
|
#http_port_min(port_number) ⇒ Object
95
96
97
|
# File 'lib/packer/builders/virtualbox.rb', line 95
def http_port_min(port_number)
self.__add_integer('http_port_min', port_number)
end
|
#iso_checksum(checksum) ⇒ Object
19
20
21
|
# File 'lib/packer/builders/virtualbox.rb', line 19
def iso_checksum(checksum)
self.__add_string('iso_checksum', checksum)
end
|
#iso_checksum_type(type) ⇒ Object
23
24
25
|
# File 'lib/packer/builders/virtualbox.rb', line 23
def iso_checksum_type(type)
self.__add_string('iso_checksum_type', type)
end
|
#iso_url(url) ⇒ Object
27
28
29
|
# File 'lib/packer/builders/virtualbox.rb', line 27
def iso_url(url)
self.__add_string('iso_url', url, %w[iso_urls])
end
|
#iso_urls(urls) ⇒ Object
31
32
33
|
# File 'lib/packer/builders/virtualbox.rb', line 31
def iso_urls(urls)
self.__add_array_of_strings('iso_urls', urls, %[iso_url])
end
|
#output_directory(directory) ⇒ Object
103
104
105
|
# File 'lib/packer/builders/virtualbox.rb', line 103
def output_directory(directory)
self.__add_string('output_directory', directory)
end
|
#shutdown_command(command) ⇒ Object
107
108
109
|
# File 'lib/packer/builders/virtualbox.rb', line 107
def shutdown_command(command)
self.__add_string('shutdown_command', command)
end
|
#shutdown_timeout(time) ⇒ Object
111
112
113
|
# File 'lib/packer/builders/virtualbox.rb', line 111
def shutdown_timeout(time)
self.__add_string('shutdown_timeout', time)
end
|
#ssh_host_port_max(port_number) ⇒ Object
119
120
121
|
# File 'lib/packer/builders/virtualbox.rb', line 119
def ssh_host_port_max(port_number)
self.__add_integer('ssh_host_port_max', port_number)
end
|
#ssh_host_port_min(port_number) ⇒ Object
115
116
117
|
# File 'lib/packer/builders/virtualbox.rb', line 115
def ssh_host_port_min(port_number)
self.__add_integer('ssh_host_port_min', port_number)
end
|
#ssh_key_path(path) ⇒ Object
123
124
125
|
# File 'lib/packer/builders/virtualbox.rb', line 123
def ssh_key_path(path)
self.__add_string('ssh_key_path', path)
end
|
#ssh_password(password) ⇒ Object
127
128
129
|
# File 'lib/packer/builders/virtualbox.rb', line 127
def ssh_password(password)
self.__add_string('ssh_password', password)
end
|
#ssh_port(port_number) ⇒ Object
131
132
133
|
# File 'lib/packer/builders/virtualbox.rb', line 131
def ssh_port(port_number)
self.__add_integer('ssh_port', port_number)
end
|
#ssh_username(username) ⇒ Object
35
36
37
|
# File 'lib/packer/builders/virtualbox.rb', line 35
def ssh_username(username)
self.__add_string('ssh_username', username)
end
|
#ssh_wait_timeout(time) ⇒ Object
135
136
137
|
# File 'lib/packer/builders/virtualbox.rb', line 135
def ssh_wait_timeout(time)
self.__add_string('ssh_wait_timeout', time)
end
|
#vboxmanage(array_of_commands) ⇒ Object
139
140
141
|
# File 'lib/packer/builders/virtualbox.rb', line 139
def vboxmanage(array_of_commands)
self.__add_array_of_array_of_strings('vboxmanage', array_of_commands)
end
|
#vboxmanage_post(array_of_commands) ⇒ Object
143
144
145
|
# File 'lib/packer/builders/virtualbox.rb', line 143
def vboxmanage_post(array_of_commands)
self.__add_array_of_array_of_strings('vboxmanage_post', array_of_commands)
end
|
#virtualbox_version_file(file) ⇒ Object
147
148
149
|
# File 'lib/packer/builders/virtualbox.rb', line 147
def virtualbox_version_file(file)
self.__add_string('virtualbox_version_file', file)
end
|
#vm_name(name) ⇒ Object
151
152
153
|
# File 'lib/packer/builders/virtualbox.rb', line 151
def vm_name(name)
self.__add_string('vm_name', name)
end
|