Skip to content

An open-source, self-hostable PaaS alternative to Vercel, Heroku & Netlify that lets you easily deploy static sites, databases, full-stack applications and 360+ one-click services on your own servers.

fix logging on ui

Andras Bacsai5ca0237e346c
diff --git a/app/Traits/ExecuteRemoteCommand.php b/app/Traits/ExecuteRemoteCommand.php
index 24e17a73dd..fd20c37644 100644
--- a/app/Traits/ExecuteRemoteCommand.php
+++ b/app/Traits/ExecuteRemoteCommand.php
@@ -41,6 +41,7 @@ trait ExecuteRemoteCommand
$remote_command = generate_ssh_command($private_key_location, $ip, $user, $port, $command);
$process = Process::timeout(3600)->idleTimeout(3600)->start($remote_command, function (string $type, string $output) use ($command, $hidden) {
+ $output = Str::of($output)->trim();
$new_log_entry = [
'command' => $command,
'output' => $output,
diff --git a/resources/views/livewire/project/application/deployment-logs.blade.php b/resources/views/livewire/project/application/deployment-logs.blade.php
index 1a0c5116fe..f354083b3e 100644
--- a/resources/views/livewire/project/application/deployment-logs.blade.php
+++ b/resources/views/livewire/project/application/deployment-logs.blade.php
@@ -18,12 +18,12 @@
@if (decode_remote_command_output($application_deployment_queue)->count() > 0)
@foreach (decode_remote_command_output($application_deployment_queue) as $line)
<div @class([
- 'font-mono break-all',
+ 'font-mono whitespace-pre-line',
'text-neutral-400' => $line['type'] == 'stdout',
'text-error' => $line['type'] == 'stderr',
'text-warning' => $line['hidden'],
])>[{{ $line['timestamp'] }}] @if ($line['hidden'])
- <br>Command: {{ $line['command'] }} <br>Output:
+ <br>COMMAND: <br>{{ $line['command'] }} <br><br>OUTPUT:
@endif{{ $line['output'] }}@if ($line['hidden'])
@endif
</div>