]> git.immae.eu Git - perso/Immae/Config/Nix.git/blob - nixops/modules/websites/ftp/release.nix
Fix peertube websockets
[perso/Immae/Config/Nix.git] / nixops / modules / websites / ftp / release.nix
1 { lib, pkgs, config, myconfig, mylibs, ... }:
2 let
3 cfg = config.services.myWebsites.Release;
4 varDir = "/var/lib/ftp/release.immae.eu";
5 env = myconfig.env.websites.release;
6 in {
7 options.services.myWebsites.Release = {
8 production = {
9 enable = lib.mkEnableOption "enable Release' website";
10 };
11 };
12
13 imports = [
14 ../commons/stats.nix
15 ];
16
17 config = lib.mkIf cfg.production.enable {
18 services.myWebsites.commons.stats.enable = true;
19 services.myWebsites.commons.stats.sites = [
20 {
21 name = "release.immae.eu";
22 conf = ./release_goaccess.conf;
23 }
24 ];
25
26 security.acme.certs."eldiron".extraDomains."release.immae.eu" = null;
27
28 services.myWebsites.production.vhostConfs.release = {
29 certName = "eldiron";
30 hosts = [ "release.immae.eu" ];
31 root = varDir;
32 extraConfig = [
33 ''
34 Use Stats release.immae.eu
35
36 Use Apaxy "${varDir}" "title .duplicity-ignore"
37 <Directory "${varDir}">
38 Use LDAPConnect
39 Options Indexes
40 AllowOverride All
41 Require all granted
42 </Directory>
43
44 <Directory "${varDir}/packages">
45 Use LDAPConnect
46 Options Indexes FollowSymlinks
47 AllowOverride None
48 Require all granted
49 </Directory>
50 ''
51 ];
52 };
53 };
54 }