aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorIsmaël Bouya <ismael.bouya@normalesup.org>2020-06-07 18:26:57 +0200
committerIsmaël Bouya <ismael.bouya@normalesup.org>2020-06-07 19:13:08 +0200
commit6c7d42fc4844bc4f9af72dab531be8377825296a (patch)
treecc202c8c5156c27d72e322520c34684e00eb1efb /modules
parent7130402cfecc196ce79c8f07a9dba71974f085e3 (diff)
downloadNix-6c7d42fc4844bc4f9af72dab531be8377825296a.tar.gz
Nix-6c7d42fc4844bc4f9af72dab531be8377825296a.tar.zst
Nix-6c7d42fc4844bc4f9af72dab531be8377825296a.zip
Add cip-ca mail website
Diffstat (limited to 'modules')
-rw-r--r--modules/private/default.nix2
-rw-r--r--modules/private/mail/sympa.nix12
-rw-r--r--modules/private/websites/cip-ca/sympa.nix28
-rw-r--r--modules/private/websites/default.nix4
4 files changed, 46 insertions, 0 deletions
diff --git a/modules/private/default.nix b/modules/private/default.nix
index 6173275..21b9845 100644
--- a/modules/private/default.nix
+++ b/modules/private/default.nix
@@ -24,6 +24,8 @@ set = {
24 chloeInte = ./websites/chloe/integration.nix; 24 chloeInte = ./websites/chloe/integration.nix;
25 chloeProd = ./websites/chloe/production.nix; 25 chloeProd = ./websites/chloe/production.nix;
26 26
27 cipcaSympa = ./websites/cip-ca/sympa.nix;
28
27 connexionswingInte = ./websites/connexionswing/integration.nix; 29 connexionswingInte = ./websites/connexionswing/integration.nix;
28 connexionswingProd = ./websites/connexionswing/production.nix; 30 connexionswingProd = ./websites/connexionswing/production.nix;
29 31
diff --git a/modules/private/mail/sympa.nix b/modules/private/mail/sympa.nix
index 669c710..f7070e6 100644
--- a/modules/private/mail/sympa.nix
+++ b/modules/private/mail/sympa.nix
@@ -98,6 +98,9 @@ in
98 sympa_virtual = pkgs.writeText "virtual.sympa" '' 98 sympa_virtual = pkgs.writeText "virtual.sympa" ''
99 sympa-request@${domain} postmaster@immae.eu 99 sympa-request@${domain} postmaster@immae.eu
100 sympa-owner@${domain} postmaster@immae.eu 100 sympa-owner@${domain} postmaster@immae.eu
101
102 sympa-request@cip-ca.fr postmaster@immae.eu
103 sympa-owner@cip-ca.fr postmaster@immae.eu
101 ''; 104 '';
102 sympa_transport = pkgs.writeText "transport.sympa" '' 105 sympa_transport = pkgs.writeText "transport.sympa" ''
103 ${domain} error:User unknown in recipient table 106 ${domain} error:User unknown in recipient table
@@ -105,6 +108,11 @@ in
105 listmaster@${domain} sympa:listmaster@${domain} 108 listmaster@${domain} sympa:listmaster@${domain}
106 bounce@${domain} sympabounce:sympa@${domain} 109 bounce@${domain} sympabounce:sympa@${domain}
107 abuse-feedback-report@${domain} sympabounce:sympa@${domain} 110 abuse-feedback-report@${domain} sympabounce:sympa@${domain}
111
112 sympa@cip-ca.fr sympa:sympa@cip-ca.fr
113 listmaster@cip-ca.fr sympa:listmaster@cip-ca.fr
114 bounce@cip-ca.fr sympabounce:sympa@cip-ca.fr
115 abuse-feedback-report@cip-ca.fr sympabounce:sympa@cip-ca.fr
108 ''; 116 '';
109 }; 117 };
110 config = { 118 config = {
@@ -157,6 +165,10 @@ in
157 webHost = "mail.immae.eu"; 165 webHost = "mail.immae.eu";
158 webLocation = "/sympa"; 166 webLocation = "/sympa";
159 }; 167 };
168 "cip-ca.fr" = {
169 webHost = "mail.cip-ca.fr";
170 webLocation = "/sympa";
171 };
160 }; 172 };
161 173
162 database = { 174 database = {
diff --git a/modules/private/websites/cip-ca/sympa.nix b/modules/private/websites/cip-ca/sympa.nix
new file mode 100644
index 0000000..bb66fc6
--- /dev/null
+++ b/modules/private/websites/cip-ca/sympa.nix
@@ -0,0 +1,28 @@
1{ lib, config, ... }:
2let
3 cfg = config.myServices.websites.cip-ca.sympa;
4in
5{
6 options.myServices.websites.cip-ca.sympa.enable = lib.mkEnableOption "enable cip-ca’s sympa website";
7 config = lib.mkIf cfg.enable {
8 services.websites.env.tools.vhostConfs.cipca_sympa = {
9 certName = "cip-ca";
10 certMainHost = "mail.cip-ca.fr";
11 hosts = [ "mail.cip-ca.fr" ];
12 root = null;
13 extraConfig = [
14 ''
15 Alias /static-sympa/ /var/lib/sympa/static_content/
16 <Directory /var/lib/sympa/static_content/>
17 Require all granted
18 AllowOverride none
19 </Directory>
20 <Location /sympa>
21 SetHandler "proxy:unix:/run/sympa/wwsympa.socket|fcgi://"
22 Require all granted
23 </Location>
24 ''
25 ];
26 };
27 };
28}
diff --git a/modules/private/websites/default.nix b/modules/private/websites/default.nix
index f192b3b..27719cc 100644
--- a/modules/private/websites/default.nix
+++ b/modules/private/websites/default.nix
@@ -220,6 +220,10 @@ in
220 production.enable = true; 220 production.enable = true;
221 }; 221 };
222 222
223 cip-ca = {
224 sympa.enable = true;
225 };
226
223 connexionswing = { 227 connexionswing = {
224 integration.enable = true; 228 integration.enable = true;
225 production.enable = true; 229 production.enable = true;