refactor(server): remove unused destinationsByServer method
This commit is contained in:
parent
571bbe235d
commit
fdb7f36347
1 changed files with 0 additions and 9 deletions
|
|
@ -270,15 +270,6 @@ public static function isUsable()
|
||||||
return Server::ownedByCurrentTeam()->whereRelation('settings', 'is_reachable', true)->whereRelation('settings', 'is_usable', true)->whereRelation('settings', 'is_swarm_worker', false)->whereRelation('settings', 'is_build_server', false)->whereRelation('settings', 'force_disabled', false);
|
return Server::ownedByCurrentTeam()->whereRelation('settings', 'is_reachable', true)->whereRelation('settings', 'is_usable', true)->whereRelation('settings', 'is_swarm_worker', false)->whereRelation('settings', 'is_build_server', false)->whereRelation('settings', 'force_disabled', false);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function destinationsByServer(string $server_id)
|
|
||||||
{
|
|
||||||
$server = Server::ownedByCurrentTeam()->findOrFail($server_id);
|
|
||||||
$standaloneDocker = collect($server->standaloneDockers->all());
|
|
||||||
$swarmDocker = collect($server->swarmDockers->all());
|
|
||||||
|
|
||||||
return $standaloneDocker->concat($swarmDocker);
|
|
||||||
}
|
|
||||||
|
|
||||||
public function settings()
|
public function settings()
|
||||||
{
|
{
|
||||||
return $this->hasOne(ServerSetting::class);
|
return $this->hasOne(ServerSetting::class);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue