Add alertmanager as supported sender and update deps
This commit is contained in:
parent
05ffc640ed
commit
973e1fd789
18 changed files with 1682 additions and 1155 deletions
|
|
@ -59,9 +59,9 @@ async def handle_event(x_gitlab_event: str, payload: Any) -> List[Tuple[str, str
|
|||
**attr.asdict(subevt, recurse=False),
|
||||
**{key: getattr(subevt, key) for key in subevt.event_properties},
|
||||
"abort": abort,
|
||||
**base_args, # type: ignore
|
||||
**base_args,
|
||||
}
|
||||
args["templates"] = templates.proxy(args) # type: ignore
|
||||
args["templates"] = templates.proxy(args)
|
||||
|
||||
html = tpl.render(**args)
|
||||
if not html or aborted:
|
||||
|
|
@ -87,4 +87,6 @@ async def parse_event(
|
|||
route: RoutingKey, payload: Any, request: Request
|
||||
) -> List[Tuple[str, str]]:
|
||||
x_gitlab_event = request.headers.get("x-gitlab-event")
|
||||
return await handle_event(x_gitlab_event, payload)
|
||||
if x_gitlab_event:
|
||||
return await handle_event(x_gitlab_event, payload)
|
||||
return []
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue