Make it 1.5 since we have some swap to work with
This commit is contained in:
@@ -1074,7 +1074,7 @@ angular.module('Application').service('Client', ['$http', '$interval', 'md5', 'N
|
||||
var needed = app.manifest.memoryLimit || DEFAULT_MEMORY_LIMIT; // RAM+Swap
|
||||
var used = this.getInstalledApps().reduce(function (prev, cur) { return prev + (cur.memoryLimit || cur.manifest.memoryLimit || DEFAULT_MEMORY_LIMIT); }, 0);
|
||||
var roundedMemory = Math.round(this.getConfig().memory / (1024 * 1024 * 1024)) * 1024 * 1024 * 1024; // round to nearest GB
|
||||
var totalMemory = roundedMemory * 1.2; // cloudron-system-setup.sh creates equal amount of swap. 1.2 factor is arbitrary
|
||||
var totalMemory = roundedMemory * 1.5; // cloudron-system-setup.sh creates equal amount of swap. 1.5 factor is arbitrary
|
||||
var available = (totalMemory || 0) - used;
|
||||
|
||||
return (available - needed) >= 0;
|
||||
|
||||
Reference in New Issue
Block a user