mirror of
https://gitlab.com/upRootNutrition/dotfiles.git
synced 2025-12-08 05:49:25 -06:00
chore: init
This commit is contained in:
commit
1b2c1ea359
891 changed files with 37053 additions and 0 deletions
33
modules/nixos/services/projectSite/default.nix
Executable file
33
modules/nixos/services/projectSite/default.nix
Executable file
|
|
@ -0,0 +1,33 @@
|
|||
{ flake, config, ... }:
|
||||
let
|
||||
inherit (flake.config.services.instances)
|
||||
projectSite
|
||||
;
|
||||
service = projectSite;
|
||||
host = flake.inputs.linkpage.secrets.domains.projectsite;
|
||||
in
|
||||
{
|
||||
services = {
|
||||
caddy = {
|
||||
virtualHosts = {
|
||||
"${host}" = {
|
||||
extraConfig = ''
|
||||
root * ${service.paths.path0}
|
||||
|
||||
file_server
|
||||
|
||||
encode gzip
|
||||
|
||||
try_files {path} /index.html
|
||||
|
||||
tls ${service.ssl.cert}/${host}/fullchain.pem ${service.ssl.key}/${host}/key.pem
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
systemd.tmpfiles.rules = [
|
||||
"Z ${service.paths.path0} 755 caddy caddy -"
|
||||
];
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue