lasthourcloud/app/Jobs/ApplicationRestartJob.php

33 lines
825 B
PHP
Raw Normal View History

2023-11-21 21:17:35 +00:00
<?php
namespace App\Jobs;
use App\Traits\ExecuteRemoteCommand;
use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldBeEncrypted;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Foundation\Bus\Dispatchable;
use Illuminate\Queue\InteractsWithQueue;
use Illuminate\Queue\SerializesModels;
2024-06-10 20:43:34 +00:00
class ApplicationRestartJob implements ShouldBeEncrypted, ShouldQueue
2023-11-21 21:17:35 +00:00
{
2024-06-10 20:43:34 +00:00
use Dispatchable, ExecuteRemoteCommand, InteractsWithQueue, Queueable, SerializesModels;
2023-11-21 21:17:35 +00:00
public $timeout = 3600;
2024-06-10 20:43:34 +00:00
2023-11-21 21:17:35 +00:00
public $tries = 1;
2024-06-10 20:43:34 +00:00
2023-11-21 21:17:35 +00:00
public string $applicationDeploymentQueueId;
2024-06-10 20:43:34 +00:00
2023-11-21 21:17:35 +00:00
public function __construct(string $applicationDeploymentQueueId)
{
$this->applicationDeploymentQueueId = $applicationDeploymentQueueId;
}
2024-06-10 20:43:34 +00:00
public function handle()
{
2023-11-21 21:17:35 +00:00
ray('Restarting application');
}
}