Improve readme and fix typos

Improve wording and fix typos in readme.
This commit is contained in:
finga 2021-11-19 14:32:18 +01:00
parent 5775870a8e
commit 33e39f0b40

View file

@ -1,6 +1,6 @@
# Webhookey
Webhookey is a web server listening for requests as for example sent by
gitea's webhooks. Further, Webhookey allows you to specify rules
Gitea's webhooks. Further, Webhookey allows you to specify rules
which are matched against the data received to trigger certain
actions.
@ -62,7 +62,10 @@ Whereas `<config_dir>` depends on the platform:
#### Metrics
A metrics page can optionally enabled to query stats of the currently
running webhookey instance. Note that stats are lost between restarts
of webhookey as those are not stored persistently.
of webhookey as those are not stored persistently. The `metrics`
structure is optional as well as the `ip_filter`. The `ip_filter`
supports either `allow` or `deny` containing a list of IPv4 and IPv6
addresses and networks.
Example:
```yaml
@ -127,14 +130,16 @@ Use values from header fields sent with the HTTP request.
Example: `{{ header X-Gitea-Event }}`.
##### Allow and Deny
To allow or deny specific network ranges source is an optional
configuration parameter which either contains an allow or a deny field
with sequences containing networks. Note that IPv6 addresses have to
be put in single quotes due to the colons.
##### IP Filter
Specific IPv4 and IPv6 addresses and/or ranges ranges can be allowed
or denied. The `ip_filter` is optional and has to contain either an
`allow` or a `deny` field which contains a sequence of IPv4 or IPv6
addresses or CIDR network ranges. Note that IPv6 addresses have to be
quoted due to the colons.
Example:
```yaml
ip_filter:
allow:
- 127.0.0.1
- 127.0.0.1/31
@ -142,6 +147,7 @@ allow:
```
```yaml
ip_filter:
deny:
- 127.0.0.1
- 127.0.0.1/31
@ -175,7 +181,7 @@ Conjunction filters contain lists of other filters.
received http(s) request header.
- `field`: The header field which should be matched.
- `regeq`: Regular expression which has to match the specified
- `regex`: Regular expression which has to match the specified
header field.
- `json`: