From 49659abaf8e4f08343835448acc4b092f2773569 Mon Sep 17 00:00:00 2001 From: Benedikt Peetz Date: Sat, 25 May 2024 22:26:01 +0200 Subject: feat(system/services/nginx)!: Change meaning of `root` key The `root` key was rather useless (it was always just the `/etc/.../` path.). This change gives it a real meaning. See the 'BREAKING CHANGE' section for more information. BREAKING CHANGE: Previously the `root` key denoted the _absolute_ root of a repository. Now it just denotes the root relative (i.e. a path within the built repository) to the repos cloning position. You should just remove the absolute part of the path (that, which is not an output in your built repository) --- system/services/nginx/default.nix | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'system/services/nginx/default.nix') diff --git a/system/services/nginx/default.nix b/system/services/nginx/default.nix index 7c2fa55..996996e 100644 --- a/system/services/nginx/default.nix +++ b/system/services/nginx/default.nix @@ -14,7 +14,7 @@ }; mkVirtHost = { domain, - root, + root ? "", url, extraSettings ? {}, }: { @@ -23,20 +23,20 @@ lib.recursiveUpdate { forceSSL = true; enableACME = true; - root = "${root}"; + root = "/etc/nginx/websites/${domain}/${root}"; } extraSettings; }; mkNixSyncRepository = { domain, - root, + root ? "", url, extraSettings ? {}, }: { name = "${domain}"; value = { - path = "${root}"; + path = "/etc/nginx/websites/${domain}/${root}"; uri = "${url}"; inherit extraSettings; }; -- cgit 1.4.1