Add core logic to allow for limited databases and allocations

This commit is contained in:
Dane Everitt 2018-03-01 20:08:27 -06:00
parent 5f6c153537
commit 87b96bdfc8
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
8 changed files with 128 additions and 43 deletions

View file

@ -69,6 +69,8 @@ class Server extends Model implements CleansAttributes, ValidableContract
'skip_scripts' => 'sometimes',
'image' => 'required',
'startup' => 'required',
'database_limit' => 'present',
'allocation_limit' => 'present',
];
/**
@ -93,6 +95,8 @@ class Server extends Model implements CleansAttributes, ValidableContract
'skip_scripts' => 'boolean',
'image' => 'string|max:255',
'installed' => 'boolean',
'database_limit' => 'nullable|integer|min:0',
'allocation_limit' => 'nullable|integer|min:0',
];
/**
@ -116,6 +120,8 @@ class Server extends Model implements CleansAttributes, ValidableContract
'egg_id' => 'integer',
'pack_id' => 'integer',
'installed' => 'integer',
'database_limit' => 'integer',
'allocation_limit' => 'integer',
];
/**