feat: add support for the HTTP handler

This commit is contained in:
ptrcnull 2024-05-23 10:11:29 +02:00
parent 70b3465674
commit 619700d0ea
Signed by: ptrcnull
GPG key ID: 411F7B30801DD9CA
2 changed files with 8 additions and 3 deletions

View file

@ -1,5 +1,7 @@
from .hetzner import HetznerHandler from .hetzner import HetznerHandler
from .http import HTTPHandler
__all__ = [ __all__ = [
'HetznerHandler' 'HetznerHandler',
'HTTPHandler'
] ]

View file

@ -7,13 +7,16 @@ from itertools import chain
import dns.resolver import dns.resolver
from .config import read_config from .config import read_config
from .handlers import HetznerHandler from .handlers import HetznerHandler, HTTPHandler
logging.basicConfig(level=logging.INFO, format='> [%(levelname)s] %(name)s: %(message)s') logging.basicConfig(level=logging.INFO, format='> [%(levelname)s] %(name)s: %(message)s')
log = logging.getLogger('nyacme_hook') log = logging.getLogger('nyacme_hook')
handlers = {'hetzner': HetznerHandler} handlers = {
'hetzner': HetznerHandler,
'http': HTTPHandler,
}
def main() -> None: def main() -> None: