blob: 4eec59ee16f1a663c87faaf535a4a9823fee1a1c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
{ config, lib, modulesPath, ... }:
let
nginxPorts = lib.concatLists
(lib.mapAttrsToList (_: cfg: (builtins.map (x: x.port) cfg.listen))
config.services.nginx.virtualHosts);
nginxMakeLocal = port: {
listen = lib.mkForce [{
inherit port;
addr = "0.0.0.0";
}];
forceSSL = lib.mkForce false;
enableACME = lib.mkForce false;
};
in {
imports = [ ../config ];
boot.isContainer = true;
networking = lib.mkForce {
domain = "aristote.vm";
interfaces = { };
defaultGateway = null;
nameservers = [ ];
firewall = { allowedTCPPorts = nginxPorts; };
};
services.filtron.rules = lib.mkForce [ ];
services.rss-bridge.debug = true;
services.nginx.virtualHosts = {
quentin = nginxMakeLocal 8080;
searx = nginxMakeLocal 8081;
rss = nginxMakeLocal 8083;
webkeydirectory = nginxMakeLocal 8084;
};
environment.etc."searx/secrets".text = ''
SECRET_KEY=secret_key
'';
}
|