chore: use Dockerfile
All checks were successful
Sample Testing / my_job (push) Successful in 2m33s

This commit is contained in:
Marcel S. Henselin 2026-04-16 10:44:30 +02:00
parent c6521c7fcf
commit f2566ae21d

25
main.go
View file

@ -171,11 +171,31 @@ func card(d templateData) ([]byte, error) {
//}`
if d.Status == "success" {
d.Add = "{\"decoratedText\": {\"startIcon\": {\"materialIcon\": {\"name\": \"check_circle\"}},\"text\": \"<b style='color: green;'>SUCCESS</b>\"}},"
d.Add = `
{
"decoratedText": {
"startIcon": {
"materialIcon": {
"name": "check_circle"
}
},
"text": "<b style=\"color: green;\">SUCCESS</b>"
}
},`
}
if d.Status == "failure" {
d.Add = "{\"decoratedText\": {\"startIcon\": {\"materialIcon\": {\"name\": \"stop_circle\"}},\"text\": \"<b style='color: red;'>FAILURE</b>\"}},"
d.Add = `
{
"decoratedText": {
"startIcon": {
"materialIcon": {
"name": "stop_circle"
}
},
"text": "<b style=\"color: red;\">FAILURE</b>"
}
},`
}
tpl := `
@ -188,7 +208,6 @@ func card(d templateData) ([]byte, error) {
"title": "{{ .Title }}",
"subtitle": "{{ .SubTitle }}",
"imageUrl": "{{ .IconUrl }}",
"imageStyle": "IMAGE",
"imageType": "SQUARE"
},
"sections": [