📁
SKYSHELL MANAGER
PHP v8.2.31
Create
Create
Path:
root
/
home
/
thevaxnx
/
nativize.com
/
staging
/
wp-includes
/
js
/
tinymce
/
themes
/
Name
Size
Perm
Actions
📁
inlite
-
0755
🗑️
🏷️
🔒
📁
modern
-
0755
🗑️
🏷️
🔒
📄
wp-links-opml.php
6.83 KB
0444
🗑️
🏷️
⬇️
✏️
🔒
Edit: ReissueCommand.php
<?php namespace App\Command; use App\Exception\CertificateException; use App\Service\Certificate\Certificate; use App\Service\Certificate\CertificateTransfer; use App\Service\Certificate\Reissue; use App\Service\CpanelApi\Adapter\CliAdapter; use App\Service\CpanelApi\CpanelApi; use Psr\Log\LoggerInterface; use Symfony\Component\Console\Attribute\AsCommand; use Symfony\Component\Console\Command\Command; use Symfony\Component\Console\Input\InputArgument; use Symfony\Component\Console\Input\InputInterface; use Symfony\Component\Console\Output\OutputInterface; #[AsCommand( name: 'app:reissue', description: 'Reissue certificate command', )] class ReissueCommand extends Command { public function __construct( private readonly CpanelApi $api, private readonly Reissue $reissue, private readonly Certificate $certificate, private readonly LoggerInterface $logger, ){ parent::__construct(); } protected function configure(): void { $this ->addArgument('domainName', InputArgument::REQUIRED, 'Domain name') ->addArgument('isAsync', InputArgument::OPTIONAL, 'Is Async Flow', false) ; } /** * @throws CertificateException */ protected function execute(InputInterface $input, OutputInterface $output): int { $adapter = $this->api->getAdapter(); if ($adapter instanceof CliAdapter) { $adapter->setUsername($_SERVER['USER']); } $certificateTransfer = new CertificateTransfer([ 'userName' => $_SERVER['USER'], 'domainName' => $input->getArgument('domainName'), ]); $certificateTransfer = $this->certificate->getCertificate($certificateTransfer); try { $this->reissue->reissueStart($certificateTransfer); } catch (\Throwable $exception) { $this->logger->error(sprintf('Error occurred reissue request: %s', $exception->getMessage())); return Command::FAILURE; } return Command::SUCCESS; } }
Save