Watch for interesting patterns in Caddy logs and send a Telegram notification.

caddy-watch

Watch for interesting patterns in Caddy logs and send a Telegram notification.

This should be used with caddy-log-kafka.

Usage

  1. Create a config file caddy-watch.yaml:
interests:
- name: private-apps
  description: First 2xx response for each (remote_ip, host) pair from private apps
  matcher:
    any:
    - host: privapp1.example.com
    - host: privapp2.example.com
    status:
      min: 200
      max: 299
  suppressDurationSecs: 300
- name: secret-data
  description: URI pattern match
  matcher:
    host: data.example.com
    uriPattern: '^\/secret\/.*$'
telegram:
  toChat: 0 # Replace with your Telegram chat id
  1. Start the service:
" \ -v "$PWD/caddy-watch.yaml:/caddy-watch.yaml" \ ghcr.io/losfair/caddy-watch \ -bootstrap-servers localhost:9093 \ -config ./caddy-watch.yaml \ -group-id com.example.caddy-watch.default \ -topics com.example.caddy.default ">
docker run -it --rm \
  -e TELEGRAM_BOT_TOKEN="
    
     " \
  -v "$PWD/caddy-watch.yaml:/caddy-watch.yaml" \
  ghcr.io/losfair/caddy-watch \
  -bootstrap-servers localhost:9093 \
  -config ./caddy-watch.yaml \
  -group-id com.example.caddy-watch.default \
  -topics com.example.caddy.default

    
Owner
Heyang Zhou
I'm interested in both the mathematical and mechanical foundations of computing. Compilers / OS / distributed systems.
Heyang Zhou
Similar Resources

A Caddy v2 extension to apply rate-limiting for HTTP requests

ratelimit A Caddy v2 extension to apply rate-limiting for HTTP requests. Installation $ xcaddy build --with github.com/owlwang/caddy-ratelimit Caddyfi

Jan 28, 2022

A very simple rate limiter in go, made as a learning project to learn go and rate limiting patterns!

A very simple rate limiter in go, made as a learning project to learn go and rate limiting patterns!

rate-limiter-go A very simple rate limiter in go, made as a learning project to learn go and rate limiting patterns! Demo: Running the project: To exe

Jun 1, 2022

An ebpf's tool to watch traffic

An ebpf's tool to watch traffic

watch-dog watch-dog利用ebpf的能力,监听指定网卡的流量来达到旁路检测流量的目的,并使用图数据库neo4j保存节点之间的流量关系。 Get go get github.com/TomatoMr/watch-dog Install make build Usage sudo ./w

Feb 5, 2022

Exposure Notification Reference Server | Covid-19 Exposure Notifications

Exposure Notification Reference Key Server COVID‑19 Exposure Notifications API Exposure Notification Reference Key Server Documentation In our continu

Jan 7, 2023

Todo-app-grpc - Go/GRPC codebase containing RealWorld examples (CRUD, auth, advanced patterns, etc)

Go/GRPC codebase containing RealWorld examples (CRUD, auth, advanced patterns, e

Oct 12, 2022

Axiom Honeycomb Proxy ships logs to Axiom and Honeycomb simultaneously.

Axiom Honeycomb Proxy Table of Contents Introduction Usage Contributing License Introduction Axiom Honeycomb Proxy ships logs to Axiom and Honeycomb s

Dec 6, 2021

Telemetry interfaces for logs and metrics allowing complete decoupling of instrumentation implementations.

Telemetry This package provides a set of Telemetry interfaces allowing you to completely decouple your libraries and packages from Logging and Metrics

Aug 9, 2022

A CLI tool to get Certificate Transparency logs of a domain name.

A CLI tool to get Certificate Transparency logs of a domain name.

crt crt is a CLI tool to get Certificate Transparency logs of a domain name. It can also enumerate subdomains. Installation If you have Go installed:

Dec 17, 2022

A tool for capturing newly issued x.509 from Certificate Transparency logs & performing periodic revocation checking.

ct-logster This repository contains the tools for collecting newly issued x509 certificates from Certificate Transparency logs, as well as performing

May 4, 2022
Comments
  • Configure Renovate

    Configure Renovate

    Mend Renovate

    Welcome to Renovate! This is an onboarding PR to help you understand and configure settings before regular Pull Requests begin.

    🚦 To activate Renovate, merge this Pull Request. To disable Renovate, simply close this Pull Request unmerged.


    Detected Package Files

    • Dockerfile (dockerfile)
    • .github/workflows/ci.yml (github-actions)
    • go.mod (gomod)

    Configuration

    🔡 Renovate has detected a custom config for this PR. Feel free to ask for help if you have any doubts and would like it reviewed.

    Important: Now that this branch is edited, Renovate can't rebase it from the base branch any more. If you make changes to the base branch that could impact this onboarding PR, please merge them manually.

    What to Expect

    With your current configuration, Renovate will create 8 Pull Requests:

    Update golang Docker tag to v1.19.3
    • Schedule: ["at any time"]
    • Branch name: renovate/golang-1.x
    • Merge into: main
    • Upgrade golang to 1.19.3-bullseye
    Update module go to 1.19
    • Schedule: ["at any time"]
    • Branch name: renovate/go-1.x
    • Merge into: main
    • Upgrade go to 1.19
    Update actions/checkout action to v3
    • Schedule: ["at any time"]
    • Branch name: renovate/actions-checkout-3.x
    • Merge into: main
    • Upgrade actions/checkout to v3
    Update docker/build-push-action action to v3
    • Schedule: ["at any time"]
    • Branch name: renovate/docker-build-push-action-3.x
    • Merge into: main
    • Upgrade docker/build-push-action to v3
    Update docker/login-action action to v2
    • Schedule: ["at any time"]
    • Branch name: renovate/docker-login-action-2.x
    • Merge into: main
    • Upgrade docker/login-action to v2
    Update docker/metadata-action action to v4
    • Schedule: ["at any time"]
    • Branch name: renovate/docker-metadata-action-4.x
    • Merge into: main
    • Upgrade docker/metadata-action to v4
    Update docker/setup-buildx-action action to v2
    • Schedule: ["at any time"]
    • Branch name: renovate/docker-setup-buildx-action-2.x
    • Merge into: main
    • Upgrade docker/setup-buildx-action to v2
    Update docker/setup-qemu-action action to v2
    • Schedule: ["at any time"]
    • Branch name: renovate/docker-setup-qemu-action-2.x
    • Merge into: main
    • Upgrade docker/setup-qemu-action to v2

    🚸 Branch creation will be limited to maximum 2 per hour, so it doesn't swamp any CI resources or spam the project. See docs for prhourlylimit for details.


    ❓ Got questions? Check out Renovate's Docs, particularly the Getting Started section. If you need any further assistance then you can also request help here.


    This PR has been generated by Mend Renovate. View repository job log here.

Related tags
A service notification for Telegram that accepts icinga vars as arguments

A service notification for Telegram that accepts icinga vars as arguments. This is mainly to workaround a limitation in Icinga Director which is unabl

Dec 19, 2021
This small Docker project is the easiest way to send notifications directly via .txt files to services like: Gotify, Telegram, SMTP (Email) or Webhook.
This small Docker project is the easiest way to send notifications directly via .txt files to services like: Gotify, Telegram, SMTP (Email) or Webhook.

This small Docker project is the easiest way to send notifications directly via .txt files to services like: Gotify, Telegram, SMTP (Email) or Webhook.

Oct 5, 2022
HTTP rate limiting module for Caddy 2

This module implements both internal and distributed HTTP rate limiting. Requests can be rejected after a specified rate limit is hit.

Jan 3, 2023
IONOS DNS module for caddy

This package contains a DNS provider module for Caddy. It is used to manage DNS records with the IONOS DNS API using libdns-ionos..

Nov 9, 2022
A Caddy v2 plugin to track requests in Pirsch analytics

caddy-pirsch-plugin A Caddy v2 plugin to track requests in Pirsch Analytics. Usage pirsch [<matcher>] { client_id <pirsch-client-id> client_se

Sep 15, 2022
Service Management App for Caddy v2

caddy-systemd Service Management App for Caddy v2. Please ask questions either here or via LinkedIn. I am happy to help you! @greenpau Please see othe

Sep 1, 2022
Access ftp through caddy

Access ftp through caddy

Dec 14, 2022
Enable requests served by caddy for distributed tracing via The OpenTracing Project.

caddy-opentracing Enable requests served by caddy for distributed tracing via The OpenTracing Project. Dependencies The Go OpenTracing Library Jaeger,

Sep 30, 2022
Caddy log filter module with a log field filter to extract the user from a basic Authorization HTTP-Header

caddy-basic-auth-filter This packages contains a log field filter to extract the user from a basic Authorization HTTP-Header. Installation xcaddy buil

May 10, 2022
netcup DNS module for caddy: dns.providers.netcup

netcup DNS module for Caddy This package contains a DNS provider module for Caddy. It can be used to manage DNS records with the netcup DNS API using

Nov 9, 2022