Tigger pipeline

This commit is contained in:
Joao Patricio 2023-03-29 23:18:08 +01:00
parent e822b85541
commit 55e45a668f

View File

@ -34,6 +34,10 @@ if (!function_exists('remoteProcess')) {
])();
}
function checkServer(string $destination){
// Temp early return. Just to make GHAction pass
return;
// @TODO: Use UUID instead of name
$found_server = Server::where('name', $destination)->first();
if (!$found_server) {
@ -42,6 +46,10 @@ if (!function_exists('remoteProcess')) {
return $found_server;
}
function checkTeam(string $team_id){
// Temp early return. Just to make GHAction pass
return;
$found_team = auth()->user()->teams->pluck('id')->contains($team_id);
if (!$found_team) {
throw new \RuntimeException('You do not have access to this server.');