pastila: nginx: isomorphis.me
This commit is contained in:
parent
c42316b4f6
commit
fe941dcf31
1 changed files with 15 additions and 1 deletions
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
let
|
let
|
||||||
up_dir = /srv/up;
|
up_dir = /srv/up;
|
||||||
|
isomorphisme_dir = /srv/isomorphis.me;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
services.nginx.enable = true;
|
services.nginx.enable = true;
|
||||||
|
@ -23,7 +24,7 @@ in
|
||||||
forceSSL = true;
|
forceSSL = true;
|
||||||
enableACME = true;
|
enableACME = true;
|
||||||
root = up_dir;
|
root = up_dir;
|
||||||
locations ={
|
locations = {
|
||||||
"/" = {
|
"/" = {
|
||||||
extraConfig = "autoindex on;";
|
extraConfig = "autoindex on;";
|
||||||
};
|
};
|
||||||
|
@ -35,4 +36,17 @@ in
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
services.nginx.virtualHosts."isomorphis.me" = {
|
||||||
|
forceSSL = true;
|
||||||
|
enableACME = true;
|
||||||
|
locations."/" = {
|
||||||
|
root = isomorphisme_dir;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
system.activationScripts."srv-permissions" = ''
|
||||||
|
chown -R up:nginx /srv/up
|
||||||
|
chown -R nginx:nginx /srv/isomorphis.me
|
||||||
|
'';
|
||||||
}
|
}
|
Loading…
Reference in a new issue