Untested code to perform an update of server build settings

This commit is contained in:
Dane Everitt
2019-11-24 15:08:54 -08:00
parent c17f9ba8a9
commit 547e8840e2
10 changed files with 306 additions and 141 deletions

View File

@@ -170,6 +170,18 @@ class Server extends Validable
return Schema::getColumnListing($this->getTable());
}
/**
* Returns the format for server allocations when communicating with the Daemon.
*
* @return array
*/
public function getAllocationMappings(): array
{
return $this->allocations->groupBy('ip')->map(function ($item) {
return $item->pluck('port');
})->toArray();
}
/**
* @return bool
*/