My Nix Configuration
1bots: 2 # Block scrapers and abusive cloud providers 3 - import: (data)/bots/ai-robots-txt.yaml 4 - import: CUSTOM/block/alibaba-cloud.yaml 5 # Allow android apps that I use 6 - name: allow-android-apps 7 user_agent_regex: Nextcloud-android|DAVx5|ICSx5 8 action: ALLOW 9 # Allow the Thunderbird Filelink app 10 - name: allow-thunderbird-filelink 11 user_agent_regex: ^Filelink for \*cloud.*$ 12 action: ALLOW 13 # Allow anyone accessing the **authenticated** DAV endpoint. 14 - name: allow-dav 15 path_regex: ^/remote.php/dav/.*$ 16 action: ALLOW 17 # Allow public shares so that I can more easily send them 18 - name: allow-public-shares 19 path_regex: ^/s/.*$ 20 action: ALLOW 21 # Allow clients to load assets to not break public shares 22 - name: allow-assets 23 action: ALLOW 24 expression: 25 any: 26 # Dist files from nextcloud core 27 - 'path.startsWith("/dist/")' 28 # Core Nextcloud files 29 - 'path.startsWith("/js/core")' 30 - 'path.startsWith("/core/css/")' 31 # Viewer app files 32 - 'path.startsWith("/apps/viewer")' 33 # Theme CSS 34 - 'path.startsWith("/apps/theming/")' 35 # Public DAV endpoint 36 - 'path.startsWith("/public.php/dav/files/")' 37 - import: (data)/common/keep-internet-working.yaml 38 - import: CUSTOM/challenge/generic-browser.yaml 39dnsbl: false