Browse Source

fix building error page

pull/24/head
Cian Butler 1 year ago
committed by System administrator
parent
commit
d0100ab2d5
2 changed files with 5 additions and 3 deletions
  1. +4
    -3
      packages/httpd-error-pages/default.nix
  2. +1
    -0
      services/httpd/shared.nix

+ 4
- 3
packages/httpd-error-pages/default.nix View File

@@ -6,7 +6,7 @@ let
(builtins.toString method)
(template {inherit title subtitle message;});

pages = builtins.map mkPage [
pages = [
{
title = "Error 401";
subtitle = "Authorization Required";
@@ -44,13 +44,14 @@ let
}
];

pageCopyCmds = (builtins.concatStringsSep "\n" (builtins.map (err_page: "cp ${err_page} $out/") pages));
pageCopyCmds = (builtins.concatStringsSep "\n" (builtins.map (page: "cp ${mkPage page} $out/${builtins.toString page.method}.html") pages));
in mkDerivation {
name = "httpd-error-pages";
src = ./includes;
installPhase = ''
mkdir -p $out
cp -ar $src/ $out
cp -ar $src/ $out/includes
${pageCopyCmds}
chmod -R 755 $out
'';
}

+ 1
- 0
services/httpd/shared.nix View File

@@ -43,6 +43,7 @@ in {
inherit hostName adminAddr;
globalRedirect = "${globalRedirect}/";
enableSSL = true;
serverAliases = [];
};

vhostProxy = hostName: proxyAddress: {


Loading…
Cancel
Save