From 3f60580d594d000fba2c3c43dabfe8ce7abdeae2 Mon Sep 17 00:00:00 2001 From: Peter Ivanov Date: Tue, 26 Nov 2024 10:34:46 +0200 Subject: [PATCH] update --- web/app/Installers/Server/Applications/PHPInstaller.php | 3 +++ web/app/Models/Domain.php | 1 + 2 files changed, 4 insertions(+) diff --git a/web/app/Installers/Server/Applications/PHPInstaller.php b/web/app/Installers/Server/Applications/PHPInstaller.php index 78a155d..48f56b9 100644 --- a/web/app/Installers/Server/Applications/PHPInstaller.php +++ b/web/app/Installers/Server/Applications/PHPInstaller.php @@ -110,11 +110,14 @@ public function install() foreach ($commands as $command) { $shellFileContent .= $command . PHP_EOL; } + $shellFileContent .= 'echo "All packages installed successfully!"' . PHP_EOL; $shellFileContent .= 'echo "DONE!"' . PHP_EOL; $shellFileContent .= 'rm -f /tmp/php-installer.sh'; file_put_contents('/tmp/php-installer.sh', $shellFileContent); + + shell_exec('chmod +x /tmp/php-installer.sh'); shell_exec('bash /tmp/php-installer.sh >> ' . $this->logFilePath . ' &'); } diff --git a/web/app/Models/Domain.php b/web/app/Models/Domain.php index 342b80f..c83eb60 100644 --- a/web/app/Models/Domain.php +++ b/web/app/Models/Domain.php @@ -252,6 +252,7 @@ public function configureVirtualHost($fixPermissions = false) $apacheVirtualHostBuilder->setHomeRoot($this->home_root); $apacheVirtualHostBuilder->setUser($findHostingSubscription->system_username); $apacheVirtualHostBuilder->setUserGroup($webUserGroup); + $apacheVirtualHostBuilder->setEnableLogs(true); if ($this->status == self::STATUS_SUSPENDED) { $suspendedPath = '/var/www/html/suspended';