mirror of
https://github.com/distribution/distribution.git
synced 2025-09-15 22:59:24 +00:00
Feature: Web Panic Reporting via hooks
This PR is for issue of "email after registry webapp panic" #41, improving my previous design (closed). It use self setting up hooks, to catch panic in web application. And, send email in hooks handle directly, to no use new http server and handler. Signed-off-by: xiekeyang <keyangxie@126.com>
This commit is contained in:
@@ -4,6 +4,20 @@ log:
|
||||
fields:
|
||||
service: registry
|
||||
environment: development
|
||||
hooks:
|
||||
- type: mail
|
||||
disabled: true
|
||||
levels:
|
||||
- panic
|
||||
options:
|
||||
smtp:
|
||||
addr: mail.example.com:25
|
||||
username: mailuser
|
||||
password: password
|
||||
insecure: true
|
||||
from: sender@example.com
|
||||
to:
|
||||
- errors@example.com
|
||||
storage:
|
||||
cache:
|
||||
blobdescriptor: redis
|
||||
@@ -41,5 +55,5 @@ notifications:
|
||||
timeout: 1s
|
||||
threshold: 10
|
||||
backoff: 1s
|
||||
disabled: true
|
||||
|
||||
disabled: true
|
||||
|
||||
|
Reference in New Issue
Block a user