Skip to content

Commit 38be7b3

Browse files
authored
use correct url in notifications (#2027)
1 parent de6a760 commit 38be7b3

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

ee/drift/controllers/notifications.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,23 +29,23 @@ func sendTestSlackWebhook(webhookURL string) error {
2929
{
3030
"type": "section",
3131
"fields": []map[string]string{
32-
{"type": "mrkdwn", "text": "<https://driftapp.digger.dev|Dev environment>"},
32+
{"type": "mrkdwn", "text": fmt.Sprintf("<%v|Dev environment>", os.Getenv("DIGGER_APP_URL"))},
3333
{"type": "mrkdwn", "text": ":large_yellow_circle: Drift detected"},
3434
},
3535
},
3636
{"type": "divider"},
3737
{
3838
"type": "section",
3939
"fields": []map[string]string{
40-
{"type": "mrkdwn", "text": "<https://driftapp.digger.dev|Staging environment>"},
40+
{"type": "mrkdwn", "text": fmt.Sprintf("<%v|Staging environment>", os.Getenv("DIGGER_APP_URL"))},
4141
{"type": "mrkdwn", "text": ":white_circle: Acknowledged drift"},
4242
},
4343
},
4444
{"type": "divider"},
4545
{
4646
"type": "section",
4747
"fields": []map[string]string{
48-
{"type": "mrkdwn", "text": "<https://driftapp.digger.dev|Prod environment>"},
48+
{"type": "mrkdwn", "text": fmt.Sprintf("<%v|Prod environment>", os.Getenv("DIGGER_APP_URL"))},
4949
{"type": "mrkdwn", "text": ":large_green_circle: No drift"},
5050
},
5151
},
@@ -108,7 +108,7 @@ func sectionBlockForProject(project models.Project) (*slack.SectionBlock, error)
108108
sectionBlock := slack.NewSectionBlock(
109109
nil,
110110
[]*slack.TextBlockObject{
111-
slack.NewTextBlockObject("mrkdwn", fmt.Sprintf("<%v/project/%v|%v>", os.Getenv("DIGGER_APP_URL"), project.ID, project.Name), false, false),
111+
slack.NewTextBlockObject("mrkdwn", fmt.Sprintf("<%v/dashboard/projects/%v|%v>", os.Getenv("DIGGER_APP_URL"), project.ID, project.Name), false, false),
112112
slack.NewTextBlockObject("mrkdwn", ":large_green_circle: No Drift", false, false),
113113
},
114114
nil,

0 commit comments

Comments
 (0)