Implement -audit-server.

To use this function, configure git-pages with e.g.:

    [audit]
    collect = true
    notify-url = "http://localhost:3004/"

and run an audit server with e.g.:

    git-pages -audit-server tcp/:3004 python $(pwd)/process.py

The provided command line is executed after appending two arguments
(audit record ID and event type), and runs in a temporary directory
with the audit record extracted into it. The following files will
be present in this directory:
  * `$1-event.json` (always)
  * `$1-manifest.json` (if type is `CommitManifest`)
  * `$1-archive.tar` (if type is `CommitManifest`)

The script must complete successfully for the event processing to
finish. The notification will keep being re-sent (by the worker) with
exponential backoff until it does.
This commit is contained in:
Catherine
2025-12-05 03:19:32 +00:00
parent 464c40db9c
commit 8c29ba3fe7
4 changed files with 149 additions and 19 deletions
+1
View File
@@ -4,3 +4,4 @@
/data
/config*.toml*
/git-pages
/site