diff options
Diffstat (limited to 'blog/posts/guide_blacklist_websites_searxng')
| -rw-r--r-- | blog/posts/guide_blacklist_websites_searxng/index.md | 21 | ||||
| -rw-r--r-- | blog/posts/guide_blacklist_websites_searxng/index.php | 1 | ||||
| -rw-r--r-- | blog/posts/guide_blacklist_websites_searxng/searxng.svg | 19 |
3 files changed, 41 insertions, 0 deletions
diff --git a/blog/posts/guide_blacklist_websites_searxng/index.md b/blog/posts/guide_blacklist_websites_searxng/index.md new file mode 100644 index 0000000..3aab326 --- /dev/null +++ b/blog/posts/guide_blacklist_websites_searxng/index.md @@ -0,0 +1,21 @@ +Quick one today. I got sick of searching for programming questions and seeing AI-generated scraped-from-stackoverflow click farm trash polluting the results, and I happen to use a personal SearXNG instance that no client-side blacklist extension on the planet is gonna support, so I went looking to see if I could blacklist them in SearXNG for like the eighth time and finally found a way using the hostname replace plugin. So here's that, because I didn't find this feature documented officially anywhere bar an [issue](https://github.com/searxng/searxng/discussions/970) on the Github repo. + +## How to do it + +First, open up your instance's config file. If you installed it directly like I did, that'll probably be `/etc/searxng/settings.yml`. If you used Docker, god help you. Anyway, find the `enabled_plugins:` section and uncomment the entry for `'Hostname replace'`, then uncomment the line `hostname_replace:` just below it. Under there you'll put your blocks: + +<p class="codetitle">/etc/searxng/settings.yml</p> + +``` +enabled_plugins: + - 'Hostname replace' +hostname_replace: + '(.*\.)?codegrepper\.com': false + '(.*\.)?geeksforgeeks\.org': false +``` + +Then restart SearXNG: + +``` +service uwsgi restart searxng +```
\ No newline at end of file diff --git a/blog/posts/guide_blacklist_websites_searxng/index.php b/blog/posts/guide_blacklist_websites_searxng/index.php new file mode 100644 index 0000000..f572f79 --- /dev/null +++ b/blog/posts/guide_blacklist_websites_searxng/index.php @@ -0,0 +1 @@ +<?php include("../post.php");
\ No newline at end of file diff --git a/blog/posts/guide_blacklist_websites_searxng/searxng.svg b/blog/posts/guide_blacklist_websites_searxng/searxng.svg new file mode 100644 index 0000000..851a0e6 --- /dev/null +++ b/blog/posts/guide_blacklist_websites_searxng/searxng.svg @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<svg xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:cc="http://creativecommons.org/ns#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:svg="http://www.w3.org/2000/svg" xmlns="http://www.w3.org/2000/svg" id="svg8" version="1.1" viewBox="0 0 92 92" height="92mm" width="92mm"> + <defs id="defs2"/> + <metadata id="metadata5"> + <rdf:RDF> + <cc:Work rdf:about=""> + <dc:format>image/svg+xml</dc:format> + <dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage"/> + <dc:title/> + </cc:Work> + </rdf:RDF> + </metadata> + <g transform="translate(-40.921303,-17.416526)" id="layer1"> + <circle r="0" style="fill:none;stroke:#000000;stroke-width:12;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" cy="92" cx="75" id="path3713"/> + <circle r="30" cy="53.902557" cx="75.921303" id="path834" style="fill:none;fill-opacity:1;stroke:#3050ff;stroke-width:10;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"/> + <path d="m 67.514849,37.91524 a 18,18 0 0 1 21.051475,3.312407 18,18 0 0 1 3.137312,21.078282" id="path852" style="fill:none;fill-opacity:1;stroke:#3050ff;stroke-width:5;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"/> + <rect transform="rotate(-46.234709)" ry="1.8669105e-13" y="122.08995" x="3.7063529" height="39.963303" width="18.846331" id="rect912" style="opacity:1;fill:#3050ff;fill-opacity:1;stroke:none;stroke-width:8;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"/> + </g> +<script xmlns=""/></svg>
\ No newline at end of file |
