-
-
Notifications
You must be signed in to change notification settings - Fork 2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
302 changed files
with
57,255 additions
and
2,151 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,12 @@ | ||
# Coolify Configuration | ||
APP_ID= | ||
APP_NAME=Coolify | ||
APP_KEY= | ||
|
||
# PostgreSQL Database Configuration | ||
DB_USERNAME=coolify | ||
DB_PASSWORD= | ||
|
||
# Redis Configuration | ||
REDIS_PASSWORD= | ||
|
||
# Pusher Configuration | ||
PUSHER_APP_ID= | ||
PUSHER_APP_KEY= | ||
PUSHER_APP_SECRET= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
<?php | ||
|
||
namespace App\Events; | ||
|
||
use App\Models\Server; | ||
use Illuminate\Broadcasting\InteractsWithSockets; | ||
use Illuminate\Foundation\Events\Dispatchable; | ||
use Illuminate\Queue\SerializesModels; | ||
|
||
class RestoreJobFinished | ||
{ | ||
use Dispatchable, InteractsWithSockets, SerializesModels; | ||
|
||
public function __construct($data) | ||
{ | ||
$scriptPath = data_get($data, 'scriptPath'); | ||
$tmpPath = data_get($data, 'tmpPath'); | ||
$container = data_get($data, 'container'); | ||
$serverId = data_get($data, 'serverId'); | ||
if (filled($scriptPath) && filled($tmpPath) && filled($container) && filled($serverId)) { | ||
if (str($tmpPath)->startsWith('/tmp/') | ||
&& str($scriptPath)->startsWith('/tmp/') | ||
&& ! str($tmpPath)->contains('..') | ||
&& ! str($scriptPath)->contains('..') | ||
&& strlen($tmpPath) > 5 // longer than just "/tmp/" | ||
&& strlen($scriptPath) > 5 | ||
) { | ||
$commands[] = "docker exec {$container} sh -c 'rm {$scriptPath}'"; | ||
$commands[] = "docker exec {$container} sh -c 'rm {$tmpPath}'"; | ||
instant_remote_process($commands, Server::find($serverId), throwError: true); | ||
} | ||
} | ||
} | ||
} |
Oops, something went wrong.