summaryrefslogtreecommitdiff
path: root/config/services/web/searx/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'config/services/web/searx/default.nix')
-rw-r--r--config/services/web/searx/default.nix51
1 files changed, 28 insertions, 23 deletions
diff --git a/config/services/web/searx/default.nix b/config/services/web/searx/default.nix
index 5998068..da4cf88 100644
--- a/config/services/web/searx/default.nix
+++ b/config/services/web/searx/default.nix
@@ -1,35 +1,40 @@
-{ config, lib, pkgs, ... }:
+{
+ config,
+ lib,
+ ...
+}:
let
cfg = {
searx = config.services.searx;
filtron = config.services.filtron;
};
-in {
- imports = [ ./searx ./filtron ./morty ];
+in
+{
+ imports = [
+ ./searx
+ ./filtron
+ ];
- services.nginx.virtualHosts.searx =
- lib.mkIf (cfg.searx.enable && cfg.filtron.enable) {
- serverName = "searx.${config.networking.domain}";
- locations = {
- "/" = {
- proxyPass = "http://${cfg.filtron.listen.address}:${
- toString cfg.filtron.listen.port
- }";
- extraConfig = ''
- proxy_set_header Host $host;
- proxy_set_header Connection $http_connection;
- proxy_set_header X-Real-IP $remote_addr;
- proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
- proxy_set_header X-Scheme $scheme;
- # proxy_set_header X-Script-Name /;
- '';
- };
- "/static/".alias = "${cfg.searx.package}/share/static/";
+ services.nginx.virtualHosts.searx = lib.mkIf (cfg.searx.enable && cfg.filtron.enable) {
+ serverName = "searx.${config.networking.domain}";
+ locations = {
+ "/" = {
+ proxyPass = "http://${cfg.filtron.listen.address}:${toString cfg.filtron.listen.port}";
+ extraConfig = ''
+ proxy_set_header Host $host;
+ proxy_set_header Connection $http_connection;
+ proxy_set_header X-Real-IP $remote_addr;
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
+ proxy_set_header X-Scheme $scheme;
+ # proxy_set_header X-Script-Name /;
+ '';
};
- forceSSL = true;
- enableACME = true;
+ "/static/".alias = "${cfg.searx.package}/share/static/";
};
+ forceSSL = true;
+ enableACME = true;
+ };
systemd.services.uwsgi.personal.monitor = true;
}