initial commit, after deletion :)
This commit is contained in:
commit
9ec37597b3
20 changed files with 1006 additions and 0 deletions
95
config/search/default.nix
Normal file
95
config/search/default.nix
Normal file
|
|
@ -0,0 +1,95 @@
|
|||
{config, ...}: let
|
||||
searxDomain = "search.${config.customOps.domain}";
|
||||
in {
|
||||
imports = [./engines.nix];
|
||||
|
||||
sops.secrets.searx.owner = "searx";
|
||||
|
||||
services.searx = {
|
||||
enable = true;
|
||||
redisCreateLocally = true;
|
||||
|
||||
limiterSettings = {
|
||||
real_ip = {
|
||||
x_for = 1;
|
||||
ipv4_prefix = 32;
|
||||
ipv6_prefix = 56;
|
||||
};
|
||||
|
||||
botdetection = {
|
||||
ip_limit = {
|
||||
filter_link_local = true;
|
||||
link_token = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
settings = {
|
||||
general = {
|
||||
debug = false;
|
||||
instance_name = "${config.customOps.owner}'s search";
|
||||
donation_url = false;
|
||||
contact_url = false;
|
||||
privacypolicy_url = false;
|
||||
enable_metrics = false;
|
||||
};
|
||||
|
||||
ui = {
|
||||
static_use_hash = true;
|
||||
default_locale = "en";
|
||||
query_in_title = false;
|
||||
infinite_scroll = true;
|
||||
center_alignment = false;
|
||||
default_theme = "simple";
|
||||
theme_args.simple_style = "auto";
|
||||
search_on_category_select = true;
|
||||
hotkeys = "vim";
|
||||
url_formatting = "full";
|
||||
};
|
||||
|
||||
search = {
|
||||
safe_search = 0;
|
||||
autocomplete_min = 2;
|
||||
autocomplete = "duckduckgo";
|
||||
favicon_resolver = "";
|
||||
ban_time_on_fail = 5;
|
||||
max_ban_time_on_fail = 120;
|
||||
};
|
||||
|
||||
server = {
|
||||
base_url = "https://${searxDomain}";
|
||||
port = 8888;
|
||||
bind_address = "127.0.0.1";
|
||||
secret_key = config.sops.secrets.searx.path;
|
||||
limiter = true;
|
||||
public_instance = true;
|
||||
image_proxy = false;
|
||||
method = "POST";
|
||||
};
|
||||
|
||||
outgoing = {
|
||||
request_timeout = 5.0;
|
||||
max_request_timeout = 15.0;
|
||||
pool_connections = 100;
|
||||
pool_maxsize = 15;
|
||||
enable_http2 = true;
|
||||
};
|
||||
|
||||
enabled_plugins = [
|
||||
"Basic Calculator"
|
||||
"Hash plugin"
|
||||
"Tor check plugin"
|
||||
"Open Access DOI rewrite"
|
||||
"Hostnames plugin"
|
||||
"Unit converter plugin"
|
||||
"Tracker URL remover"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
services.nginx.virtualHosts.${searxDomain} = {
|
||||
forceSSL = true;
|
||||
enableACME = true;
|
||||
locations."/".proxyPass = "http://localhost:8888";
|
||||
};
|
||||
}
|
||||
163
config/search/engines.nix
Normal file
163
config/search/engines.nix
Normal file
|
|
@ -0,0 +1,163 @@
|
|||
{lib, ...}: {
|
||||
services.searx.settings.engines = lib.mapAttrsToList (name: value: {inherit name;} // value) {
|
||||
# unnecessary
|
||||
"dictzone".disabled = true;
|
||||
"lingva".disabled = true;
|
||||
"mymemory translated".disabled = true;
|
||||
"mozhi".disabled = true;
|
||||
"presearch".disabled = true;
|
||||
"presearch images".disabled = true;
|
||||
"presearch videos".disabled = true;
|
||||
"presearch news".disabled = true;
|
||||
"seznam".disabled = true;
|
||||
"goo".disabled = true;
|
||||
"naver".disabled = true;
|
||||
"naver videos".disabled = true;
|
||||
"naver images".disabled = true;
|
||||
"naver news".disabled = true;
|
||||
"alexandria".disabled = true;
|
||||
"ask".disabled = true;
|
||||
"crowdview".disabled = true;
|
||||
"mwmbl".disabled = true;
|
||||
"searchmysite".disabled = true;
|
||||
"stract".disabled = true;
|
||||
"bpb".disabled = true;
|
||||
"tagesschau".disabled = true;
|
||||
"wikimini".disabled = true;
|
||||
"findthatmeme".disabled = true;
|
||||
"frinkiac".disabled = true;
|
||||
"livespace".disabled = true;
|
||||
"sepiasearch".disabled = true;
|
||||
"mediathekviewweb".disabled = true;
|
||||
"ina".disabled = true;
|
||||
"niconio".disabled = true;
|
||||
"acfun".disabled = true;
|
||||
"iqiyi".disabled = true;
|
||||
"wolframalpha".disabled = true;
|
||||
"ansa".disabled = true;
|
||||
"il post".disabled = true;
|
||||
"deezer".disabled = true;
|
||||
"habrahabr".disabled = true;
|
||||
"btdigg".disabled = true;
|
||||
"duden".disabled = true;
|
||||
"woxikon.de synonyme".disabled = true;
|
||||
"jisho".disabled = true;
|
||||
"moviepilot".disabled = true;
|
||||
"senscritique".disabled = true;
|
||||
"geizhals".disabled = true;
|
||||
"duckduckgo weather".disabled = true;
|
||||
"openmeteo".disabled = true;
|
||||
"fyyd".disabled = true;
|
||||
"yummly".disabled = true;
|
||||
"chefkoch".disabled = true;
|
||||
"destatis".disabled = true;
|
||||
# big brother
|
||||
"google".disabled = true;
|
||||
"google play movies".disabled = true;
|
||||
"google play apps".disabled = true;
|
||||
"google news".disabled = true;
|
||||
"google images".disabled = true;
|
||||
"google videos".disabled = true;
|
||||
"google scholar".disabled = true;
|
||||
"youtube".disabled = true;
|
||||
"bing".disabled = true;
|
||||
"bing images".disabled = true;
|
||||
"bing videos".disabled = true;
|
||||
"bing news".disabled = true;
|
||||
"microsoft learn".disabled = true;
|
||||
"material icons".disabled = true;
|
||||
"apple maps".disabled = true;
|
||||
"apple app store".disabled = true;
|
||||
"goodreads".disabled = true;
|
||||
# captcha
|
||||
"mojeek".disabled = true;
|
||||
"mojeek images".disabled = true;
|
||||
"mojeek news".disabled = true;
|
||||
"qwant".disabled = true;
|
||||
"qwant images".disabled = true;
|
||||
"qwant videos".disabled = true;
|
||||
"qwant news".disabled = true;
|
||||
"cppreference".disabled = true;
|
||||
"lib.rs".disabled = true;
|
||||
"sourcehut".disabled = true;
|
||||
"free software directory".disabled = true;
|
||||
"searchcode code".disabled = true;
|
||||
"pdbe".disabled = true;
|
||||
"1337x".disabled = true;
|
||||
"kickass".disabled = true;
|
||||
"library genesis".disabled = true;
|
||||
"openrepos".disabled = true;
|
||||
"tokyotoshokan".disabled = true;
|
||||
"startpage".disabled = true;
|
||||
"mulvaddelta".disabled = true;
|
||||
"mulvaddelta brave".disabled = true;
|
||||
"brave".disabled = true;
|
||||
# non-free
|
||||
"tineye".disabled = true;
|
||||
"1x".disabled = true;
|
||||
"adobe stock".disabled = true;
|
||||
"adobe stock video".disabled = true;
|
||||
"adobe stock audio".disabled = true;
|
||||
"deviantart".disabled = true;
|
||||
"flickr".disabled = true;
|
||||
"imgur".disabled = true;
|
||||
"library of congress".disabled = true;
|
||||
"pinterest".disabled = true;
|
||||
"unsplash".disabled = true;
|
||||
"bilibili".disabled = true;
|
||||
"dailymotion".disabled = true;
|
||||
"vimeo".disabled = true;
|
||||
"yahoo".disabled = true;
|
||||
"yahoo news".disabled = true;
|
||||
"genius".disabled = true;
|
||||
"mixcloud".disabled = true;
|
||||
"soundcloud".disabled = true;
|
||||
"huggingface".disabled = true;
|
||||
"huggingface datasets".disabled = true;
|
||||
"huggingface spaces".disabled = true;
|
||||
"9gag".disabled = true;
|
||||
"reddit".disabled = true;
|
||||
"imdb".disabled = true;
|
||||
"rottentomatoes".disabled = true;
|
||||
# shady
|
||||
"right dao".disabled = true;
|
||||
"quark".disabled = true;
|
||||
"quark images".disabled = true;
|
||||
"sogou".disabled = true;
|
||||
"sogou images".disabled = true;
|
||||
"sogou wechat".disabled = true;
|
||||
"sogou videos".disabled = true;
|
||||
# LLM
|
||||
"cloudflareai".disabled = true;
|
||||
"yacy".disabled = true;
|
||||
"yacy images".disabled = true;
|
||||
"yep".disabled = true;
|
||||
"yep images".disabled = true;
|
||||
"yep news".disabled = true;
|
||||
"360search".disabled = true;
|
||||
"360search videos".disabled = true;
|
||||
"baidu".disabled = true;
|
||||
"baidu images".disabled = true;
|
||||
"baidu kaifa".disabled = true;
|
||||
"seekr images".disabled = true;
|
||||
"seekr news".disabled = true;
|
||||
"seekr videos".disabled = true;
|
||||
"github".disabled = true;
|
||||
# censorship
|
||||
"reuters".disabled = true;
|
||||
# far-right/disinformation/misinformation
|
||||
"bitchute".disabled = true;
|
||||
"rumble".disabled = true;
|
||||
"bandcamp".disabled = true;
|
||||
# slow
|
||||
"crossref".disabled = true;
|
||||
"wikidata".disabled = true;
|
||||
|
||||
# enabled
|
||||
"wiby".disabled = false;
|
||||
"duckduckgo".disabled = false;
|
||||
"duckduckgo images".disabled = false;
|
||||
"duckduckgo videos".disabled = false;
|
||||
"duckduckgo news".disabled = false;
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue