Anubis module for Caddy
1localhost {
2 @anubis {
3 # This matcher allows you to select specific paths for Anubis to handle.
4 # If you want to handle all paths, remove this block and use `anubis {...}` instead!
5 path / # don't let AI scrapers browse the file index
6 path /.within.website/* # required for anubis to work
7
8 not path /api/* # exclude api routes from anubis
9 }
10
11 log http.handlers.anubis {
12 level DEBUG
13 }
14
15 anubis @anubis {
16 # This setting gets overridden a lot by the default bot policy.
17 difficulty 4
18
19 # Custom bot policy
20 policy_fname example/botPolicy.yaml
21
22 # FIXME: required for OpenGraph passthrough!
23 ## TODO: access upstream directly somehow?
24 ## otherwise anubis may trigger itself
25 ## additionally, https://github.com/TecharoHQ/anubis/issues/329
26 # target http://localhost:8080
27 }
28
29 file_server browse
30}