diff options
-rw-r--r-- | bbot/agent/machine.cxx | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/bbot/agent/machine.cxx b/bbot/agent/machine.cxx index 41d124c..c884f8c 100644 --- a/bbot/agent/machine.cxx +++ b/bbot/agent/machine.cxx @@ -266,12 +266,20 @@ namespace bbot // heuristics that we will use is 4G or 1G per CPU, whichever is greater // and the rest divide equally between the host and the VM. // + // But the experience showed that we actually want to be able to precisely + // control the amount of RAM assigned to VMs (e.g., for tmpfs size) and + // without back-fudging for this heuristics. + // +#if 0 size_t ram ((cpus < 4 ? 4 : cpus) * 1024 * 1024); // Kb. if (ram > ops.ram ()) ram = ops.ram (); else ram += (ops.ram () - ram) / 2; +#else + size_t ram (ops.ram ()); +#endif // If we have options, use that instead of the default network and // disk configuration. |