aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--nixops/modules/websites/capitaines/default.nix19
1 files changed, 16 insertions, 3 deletions
diff --git a/nixops/modules/websites/capitaines/default.nix b/nixops/modules/websites/capitaines/default.nix
index 8073955..08f6dd3 100644
--- a/nixops/modules/websites/capitaines/default.nix
+++ b/nixops/modules/websites/capitaines/default.nix
@@ -13,16 +13,17 @@ in {
13 }; 13 };
14 14
15 config = lib.mkIf cfg.production.enable { 15 config = lib.mkIf cfg.production.enable {
16 security.acme.certs."capitaines_mastodon" = config.services.myCertificates.certConfig // { 16 security.acme.certs."capitaines" = config.services.myCertificates.certConfig // {
17 domain = "mastodon.capitaines.fr"; 17 domain = "mastodon.capitaines.fr";
18 extraDomains = { "capitaines.fr" = null; };
18 }; 19 };
19 system.extraSystemBuilderCmds = '' 20 system.extraSystemBuilderCmds = ''
20 mkdir -p $out/webapps 21 mkdir -p $out/webapps
21 ln -s ${siteDir} $out/webapps/${webappName} 22 ln -s ${siteDir} $out/webapps/${webappName}
22 ''; 23 '';
23 24
24 services.myWebsites.production.vhostConfs.capitaines = { 25 services.myWebsites.production.vhostConfs.capitaines_mastodon = {
25 certName = "capitaines_mastodon"; 26 certName = "capitaines";
26 hosts = [ "mastodon.capitaines.fr" ]; 27 hosts = [ "mastodon.capitaines.fr" ];
27 root = root; 28 root = root;
28 extraConfig = [ 29 extraConfig = [
@@ -36,5 +37,17 @@ in {
36 '' 37 ''
37 ]; 38 ];
38 }; 39 };
40
41 services.myWebsites.production.vhostConfs.capitaines = {
42 certName = "capitaines";
43 hosts = [ "capitaines.fr" ];
44 root = "/run/current-system/webapps/_www";
45 extraConfig = [ ''
46 <Directory /run/current-system/webapps/_www>
47 DirectoryIndex index.htm
48 Require all granted
49 </Directory>
50 '' ];
51 };
39 }; 52 };
40} 53}