blob: 424ebd48321b45d05a2b6a97554e68158c69e536 (
plain) (
tree)
|
|
{ lib, pkgs, config, myconfig, ... }:
let
adminer = pkgs.callPackage ../commons/adminer.nix {};
cfg = config.myServices.websites.florian.integration;
varDir = "/var/lib/ftp/florian";
env = myconfig.env.websites.florian;
in {
options.myServices.websites.florian.integration.enable = lib.mkEnableOption "enable Florian's website integration";
config = lib.mkIf cfg.enable {
security.acme.certs."ftp".extraDomains."florian.immae.eu" = null;
services.websites.integration.modules = adminer.apache.modules;
services.websites.integration.vhostConfs.florian = {
certName = "eldiron";
addToCerts = true;
hosts = [ "florian.immae.eu" ];
root = "${varDir}/florian.immae.eu";
extraConfig = [
adminer.apache.vhostConf
''
ServerAdmin ${env.server_admin}
<Directory ${varDir}/florian.immae.eu>
DirectoryIndex index.php index.htm index.html
Options Indexes FollowSymLinks MultiViews Includes
AllowOverride None
Require all granted
</Directory>
''
];
};
};
}
|