Default to OOM killer being disabled, add back configuration option per-server

This commit is contained in:
Dane Everitt 2019-08-03 13:41:24 -07:00
parent 2198269a65
commit 81409947cf
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
9 changed files with 38 additions and 3 deletions

View file

@ -85,6 +85,7 @@ class BuildModificationService
}
$server = $this->repository->withFreshModel()->update($server->id, [
'oom_disabled' => array_get($data, 'oom_disabled'),
'memory' => array_get($data, 'memory'),
'swap' => array_get($data, 'swap'),
'io' => array_get($data, 'io'),
@ -97,6 +98,7 @@ class BuildModificationService
$allocations = $this->allocationRepository->findWhere([['server_id', '=', $server->id]]);
$build['oom_disabled'] = $server->oom_disabled;
$build['memory'] = (int) $server->memory;
$build['swap'] = (int) $server->swap;
$build['io'] = (int) $server->io;