Skip to content

Commit

Permalink
chore: minor improvements
Browse files Browse the repository at this point in the history
1. Replace the `any` type in the `AlertRequestBody` interface fields
with more specific types.

2. Fix the maximal version of the Alertmanager that is compatible with
the current critical alerts code in the `docker-compose`.
  • Loading branch information
AlexanderLukin committed Jan 23, 2025
1 parent b9528e2 commit 627cbc9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ services:
- '8083:8080'

alertmanager:
image: prom/alertmanager:v0.24.0
image: prom/alertmanager:v0.26.0
container_name: alertmanager
restart: unless-stopped
deploy:
Expand Down
9 changes: 7 additions & 2 deletions src/common/alertmanager/alerts/BasicAlert.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,13 @@ import { RegistrySourceOperator } from 'validators-registry';
export interface AlertRequestBody {
startsAt: string;
endsAt: string;
labels: any;
annotations: any;
labels: {
[key: string]: string;
};
annotations: {
summary: string;
description: string;
};
}

export interface PreparedToSendAlert {
Expand Down

0 comments on commit 627cbc9

Please sign in to comment.