Skip to content

Commit

Permalink
fix(core): improve deployment failure Slack notification formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
andrasbacsai committed Feb 4, 2025
1 parent 4c9aa24 commit 3da921e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions app/Notifications/Application/DeploymentFailed.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public function __construct(Application $application, string $deployment_uuid, ?
if (str($this->fqdn)->explode(',')->count() > 1) {
$this->fqdn = str($this->fqdn)->explode(',')->first();
}
$this->deployment_url = base_url()."/project/{$this->project_uuid}/environments/{$this->environment_uuid}/application/{$this->application->uuid}/deployment/{$this->deployment_uuid}";
$this->deployment_url = base_url()."/project/{$this->project_uuid}/environment/{$this->environment_uuid}/application/{$this->application->uuid}/deployment/{$this->deployment_uuid}";
}

public function via(object $notifiable): array
Expand Down Expand Up @@ -175,9 +175,9 @@ public function toSlack(): SlackMessage
}
}

$description .= "\n\n**Project:** ".data_get($this->application, 'environment.project.name');
$description .= "\n**Environment:** {$this->environment_name}";
$description .= "\n**Deployment Logs:** {$this->deployment_url}";
$description .= "\n\n*Project:* ".data_get($this->application, 'environment.project.name');
$description .= "\n*Environment:* {$this->environment_name}";
$description .= "\n*<{$this->deployment_url}|Deployment Logs>*";

return new SlackMessage(
title: $title,
Expand Down

0 comments on commit 3da921e

Please sign in to comment.