mirror of
https://github.com/SebastianStork/nixos-config.git
synced 2026-03-23 01:49:08 +01:00
Compare commits
No commits in common. "31e26cfe37982634a819a08eb7444c02a7ff7723" and "de5314fc31059b7812fb613a91624ce90b80bc07" have entirely different histories.
31e26cfe37
...
de5314fc31
5 changed files with 2 additions and 76 deletions
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
|
|
@ -158,7 +158,7 @@ jobs:
|
||||||
-d "$body" \
|
-d "$body" \
|
||||||
https://ntfy.sh/splitleaf
|
https://ntfy.sh/splitleaf
|
||||||
- name: Notify failure
|
- name: Notify failure
|
||||||
if: needs.await-deploy.result == 'failure' || needs.await-deploy.result == 'skipped'
|
if: needs.await-deploy.result == 'failure'
|
||||||
env:
|
env:
|
||||||
SHA: ${{ github.sha }}
|
SHA: ${{ github.sha }}
|
||||||
COMMIT_MSG: ${{ github.event.head_commit.message }}
|
COMMIT_MSG: ${{ github.event.head_commit.message }}
|
||||||
|
|
|
||||||
|
|
@ -71,11 +71,6 @@
|
||||||
enable = true;
|
enable = true;
|
||||||
domain = "home.${config.custom.networking.overlay.domain}";
|
domain = "home.${config.custom.networking.overlay.domain}";
|
||||||
};
|
};
|
||||||
|
|
||||||
searxng = {
|
|
||||||
enable = true;
|
|
||||||
domain = "search.${config.custom.networking.overlay.domain}";
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -40,16 +40,6 @@ in
|
||||||
|> lib.map (glance: glance.domain)
|
|> lib.map (glance: glance.domain)
|
||||||
|> lib.head;
|
|> lib.head;
|
||||||
};
|
};
|
||||||
searchEngine = lib.mkOption {
|
|
||||||
type = lib.types.nonEmptyStr;
|
|
||||||
default =
|
|
||||||
allHosts
|
|
||||||
|> lib.attrValues
|
|
||||||
|> lib.map (host: host.config.custom.web-services.searxng)
|
|
||||||
|> lib.filter (searxng: searxng.enable)
|
|
||||||
|> lib.map (searxng: searxng.domain)
|
|
||||||
|> lib.head;
|
|
||||||
};
|
|
||||||
extensions = lib.mkOption {
|
extensions = lib.mkOption {
|
||||||
type = lib.types.attrsOf (
|
type = lib.types.attrsOf (
|
||||||
lib.types.submodule (
|
lib.types.submodule (
|
||||||
|
|
@ -125,16 +115,6 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
extraConfig = lib.readFile "${inputs.betterfox}/user.js";
|
extraConfig = lib.readFile "${inputs.betterfox}/user.js";
|
||||||
|
|
||||||
search = {
|
|
||||||
force = true;
|
|
||||||
default = "searxng";
|
|
||||||
privateDefault = "searxng";
|
|
||||||
engines.searxng = {
|
|
||||||
name = "searxng";
|
|
||||||
urls = lib.singleton { template = "https://${cfg.searchEngine}/search?q={searchTerms}"; };
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
policies.ExtensionSettings =
|
policies.ExtensionSettings =
|
||||||
|
|
|
||||||
|
|
@ -87,7 +87,7 @@ in
|
||||||
widgets =
|
widgets =
|
||||||
lib.singleton {
|
lib.singleton {
|
||||||
type = "search";
|
type = "search";
|
||||||
search-engine = "https://search.splitleaf.de/search?q={QUERY}";
|
search-engine = "google";
|
||||||
autofocus = true;
|
autofocus = true;
|
||||||
}
|
}
|
||||||
++ applicationSites
|
++ applicationSites
|
||||||
|
|
|
||||||
|
|
@ -1,49 +0,0 @@
|
||||||
{ config, lib, ... }:
|
|
||||||
let
|
|
||||||
cfg = config.custom.web-services.searxng;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
options.custom.web-services.searxng = {
|
|
||||||
enable = lib.mkEnableOption "";
|
|
||||||
domain = lib.mkOption {
|
|
||||||
type = lib.types.nonEmptyStr;
|
|
||||||
default = "";
|
|
||||||
};
|
|
||||||
port = lib.mkOption {
|
|
||||||
type = lib.types.port;
|
|
||||||
default = 27916;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
|
||||||
services.searx = {
|
|
||||||
enable = true;
|
|
||||||
settings = {
|
|
||||||
server = {
|
|
||||||
inherit (cfg) port;
|
|
||||||
secret_key = "unnecessary";
|
|
||||||
};
|
|
||||||
ui.center_alignment = true;
|
|
||||||
plugins = {
|
|
||||||
"searx.plugins.calculator.SXNGPlugin".active = true;
|
|
||||||
"searx.plugins.infinite_scroll.SXNGPlugin".active = true;
|
|
||||||
"searx.plugins.self_info.SXNGPlugin".active = true;
|
|
||||||
};
|
|
||||||
search = {
|
|
||||||
autocomplete = "duckduckgo";
|
|
||||||
favicon_resolver = "duckduckgo";
|
|
||||||
};
|
|
||||||
hostnames.remove = [ ''(.*\.)?nixos.wiki'' ];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
custom = {
|
|
||||||
services.caddy.virtualHosts.${cfg.domain}.port = cfg.port;
|
|
||||||
|
|
||||||
meta.sites.${cfg.domain} = {
|
|
||||||
title = "SearXNG";
|
|
||||||
icon = "sh:searxng";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue