Created
January 13, 2013 19:17
-
-
Save sheenobu/4525749 to your computer and use it in GitHub Desktop.
Vagrant hard drive function.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Vagrant::Config::Top.class_eval do | |
| def hd(name,size,port) | |
| self.vm.customize [ "createhd", "--filename","#{name}.vmdk", "--size", size.to_s, "--format", "vmdk" ] | |
| self.vm.customize ["storageattach", :id, "--storagectl", "SATA Controller", "--port", port.to_s, "--device", "0", "--type", "hdd", "--medium", "#{name}.vmdk"] | |
| end | |
| end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment