Skip to content

Instantly share code, notes, and snippets.

@phips
Forked from machixian/additional_disk_to_vagrant.rb
Last active December 20, 2015 23:09
Show Gist options
  • Save phips/6210401 to your computer and use it in GitHub Desktop.
Save phips/6210401 to your computer and use it in GitHub Desktop.
Vagrant.configure("2") do |config|
config.vm.box = "base"
# strat with Vagrant configuration v2 need specify VM provider
config.vm.provider :virtualbox do |vb|
file_to_disk = '/tmp/large_disk.vdi'
# disk size 50GB
vb.customize ['createhd', '--filename', file_to_disk, '--size', 50 * 1024]
vb.customize ['storageattach', :id, '--storagectl', 'SATA', '--port', 1, '--device', 0, '--type', 'hdd', '--medium', file_to_disk]
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment