Vagrant VM memory environment variable.

Has Vagrant try to read `KUBERNETES_MEMORY` environment varilable when setting
$vm_mem.

fixes #3792
This commit is contained in:
Ryan Fowler
2015-02-08 17:53:35 -06:00
parent 0059c39211
commit 749ae3d661
2 changed files with 11 additions and 2 deletions

4
Vagrantfile vendored
View File

@@ -50,11 +50,11 @@ else # sorry Windows folks, I can't help you
$vm_cpus = 2
end
# Give VM 1024MB of RAM
# Give VM 1024MB of RAM by default
# In Fedora VM, tmpfs device is mapped to /tmp. tmpfs is given 50% of RAM allocation.
# When doing Salt provisioning, we copy approximately 200MB of content in /tmp before anything else happens.
# This causes problems if anything else was in /tmp or the other directories that are bound to tmpfs device (i.e /run, etc.)
$vm_mem = 1024
$vm_mem = (ENV['KUBERNETES_MEMORY'] || 1024).to_i
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
def customize_vm(config)