fix: delete event to deleting
This commit is contained in:
parent
1c8f92d3b7
commit
91db1953ff
@ -22,7 +22,7 @@ protected static function booted()
|
||||
'project_id' => $project->id,
|
||||
]);
|
||||
});
|
||||
static::deleted(function ($project) {
|
||||
static::deleting(function ($project) {
|
||||
$project->environments()->delete();
|
||||
$project->settings()->delete();
|
||||
});
|
||||
|
@ -16,7 +16,7 @@ class Service extends BaseModel
|
||||
|
||||
protected static function booted()
|
||||
{
|
||||
static::deleted(function ($service) {
|
||||
static::deleting(function ($service) {
|
||||
$storagesToDelete = collect([]);
|
||||
foreach ($service->applications()->get() as $application) {
|
||||
instant_remote_process(["docker rm -f {$application->name}-{$service->uuid}"], $service->server, false);
|
||||
|
@ -28,7 +28,7 @@ protected static function booted()
|
||||
'is_readonly' => true
|
||||
]);
|
||||
});
|
||||
static::deleted(function ($database) {
|
||||
static::deleting(function ($database) {
|
||||
// Stop Container
|
||||
instant_remote_process(
|
||||
["docker rm -f {$database->uuid}"],
|
||||
|
Loading…
Reference in New Issue
Block a user