mirror of
https://github.com/tiennm99/coolify.git
synced 2026-09-20 04:23:16 +00:00
wip
This commit is contained in:
1 parent
a0da981ec7
commit
75326f6626
27 files changed
+1770
-95
No files matched your search
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
|
||||
use App\Services\CoolifyProcess;
|
||||
use Illuminate\Process\ProcessResult;
|
||||
use Spatie\Activitylog\Contracts\Activity;
|
||||
|
||||
if (! function_exists('coolifyProcess')) {
|
||||
|
||||
/**
|
||||
* Run a Coolify Process, which SSH's into a machine to run the command(s).
|
||||
*
|
||||
*/
|
||||
function coolifyProcess($command, $destination): Activity|ProcessResult
|
||||
{
|
||||
$process = resolve(CoolifyProcess::class, [
|
||||
'destination' => $destination,
|
||||
'command' => $command,
|
||||
]);
|
||||
|
||||
$activityLog = $process();
|
||||
|
||||
return $activityLog;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user