use blade as conmmands template (#444)

* use blade as conmmands template

* fix lint

* fix ssl
This commit is contained in:
Saeed Vaziry
2025-01-27 21:27:58 +01:00
committed by GitHub
parent a73476c1dd
commit cdbde063f0
208 changed files with 1080 additions and 1012 deletions

View File

@ -2,19 +2,20 @@
namespace App\SSH\Composer;
use App\Exceptions\SSHError;
use App\Models\Site;
use App\SSH\HasScripts;
class Composer
{
use HasScripts;
/**
* @throws SSHError
*/
public function installDependencies(Site $site): void
{
$site->server->ssh($site->user)->exec(
$this->getScript('composer-install.sh', [
view('ssh.composer.composer-install', [
'path' => $site->path,
'php_version' => $site->php_version,
'phpVersion' => $site->php_version,
]),
'composer-install',
$site->id

View File

@ -1,7 +0,0 @@
if ! cd __path__; then
echo 'VITO_SSH_ERROR' && exit 1
fi
if ! php__php_version__ /usr/local/bin/composer install --no-interaction --prefer-dist --optimize-autoloader --no-dev; then
echo 'VITO_SSH_ERROR' && exit 1
fi