about summary refs log tree commit diff
path: root/nix/hosts/corrino/www/talks.emile.space.nix
blob: 3bc06f536756d4b0512e3d9e267a7e20d8189925 (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
45
{ config, pkgs, ... }:

{
  services = {
    # so the default pretalx module doesn't allow TLS foo by default, don't ask
    # me why...
    nginx.virtualHosts."talks.emile.space" = {
      forceSSL = true;
      enableACME = true;
      serverAliases = [ "talks.hackoween.de" ];
    };

    pretalx = {
      package = pkgs.pretalx;
      enable = true;
      plugins = with config.services.pretalx.package.plugins; [ pages ];
      user = "pretalx";
      group = "pretalx";
      nginx = {
        enable = true;
        domain = "talks.emile.space";
      };
      settings = {
        site = {
          url = "https://talks.emile.space";
          debug = false;
          csp = "https://talks.emile.space,http://localhost:8080,'self'";
        };
        mail = {
          from = "tickets@emile.space";
          host = "mail.emile.space";
          user = "mail";
          password = "${config.age.secrets.mail_password.path}";
          port = 1025;
          tls = "on";
          ssl = "off";
        };
        redis = {
          session = true;
          location = "unix://${config.services.redis.servers.pretalx.unixSocket}?db=0";
        };
      };
    };
  };
}