rename e11sync-frontend -> e11sync-caddyfile
This commit is contained in:
parent
b3da3c8294
commit
34ba024d56
2
Makefile
2
Makefile
@ -17,7 +17,7 @@ run-backend:
|
||||
|
||||
.PHONY: run-frontend
|
||||
run-frontend:
|
||||
nix run .#e11sync-frontend
|
||||
nix run .#e11sync-caddyfile
|
||||
|
||||
.PHONY: vm
|
||||
vm:
|
||||
|
@ -44,7 +44,7 @@
|
||||
};
|
||||
in {
|
||||
packages = {
|
||||
inherit (pkgs) e11sync-static e11sync-frontend e11sync-backend;
|
||||
inherit (pkgs) e11sync-static e11sync-caddyfile e11sync-backend;
|
||||
};
|
||||
|
||||
checks = {
|
||||
@ -66,9 +66,9 @@
|
||||
};
|
||||
|
||||
apps = {
|
||||
e11sync-frontend = {
|
||||
e11sync-caddyfile = {
|
||||
type = "app";
|
||||
name = "e11sync-frontend";
|
||||
name = "e11sync-caddyfile";
|
||||
program = toString (pkgs.writeShellScript "wrapper" ''
|
||||
exec ${pkgs.caddy}/bin/caddy run --config ${pkgs.writeTextFile {
|
||||
name = "Caddyfile";
|
||||
@ -79,7 +79,7 @@
|
||||
debug
|
||||
}
|
||||
:8001
|
||||
${builtins.readFile "${pkgs.e11sync-frontend}"}
|
||||
${builtins.readFile "${pkgs.e11sync-caddyfile}"}
|
||||
'';
|
||||
}} --adapter caddyfile'');
|
||||
};
|
||||
|
@ -6,7 +6,7 @@ geoip2-tarball: {
|
||||
}: let
|
||||
overlay = import ../../overlays.nix geoip2-tarball;
|
||||
pkgs1 = pkgs.extend overlay;
|
||||
inherit (pkgs1) e11sync-backend e11sync-frontend;
|
||||
inherit (pkgs1) e11sync-backend e11sync-caddyfile;
|
||||
in {
|
||||
options.e11sync = with lib.types; {
|
||||
enable = lib.mkEnableOption "Enable e11sync";
|
||||
@ -82,6 +82,6 @@ in {
|
||||
};
|
||||
|
||||
services.caddy.virtualHosts."${cfg.vhost}".extraConfig =
|
||||
builtins.readFile "${e11sync-frontend}";
|
||||
builtins.readFile "${e11sync-caddyfile}";
|
||||
};
|
||||
}
|
||||
|
@ -13,6 +13,6 @@ in {
|
||||
inherit geoip2-tarball;
|
||||
};
|
||||
e11sync-static = withDjango5.callPackage ./pkgs/e11sync-static.nix {};
|
||||
e11sync-frontend = withDjango5.callPackage ./pkgs/e11sync-frontend.nix {};
|
||||
e11sync-caddyfile = withDjango5.callPackage ./pkgs/e11sync-caddyfile.nix {};
|
||||
e11sync-backend = withDjango5.callPackage ./pkgs/e11sync-backend.nix {};
|
||||
})
|
||||
|
@ -4,7 +4,7 @@
|
||||
backendPort ? 8002,
|
||||
}:
|
||||
writeTextFile {
|
||||
name = "e11sync-frontend";
|
||||
name = "e11sync-caddyfile";
|
||||
text = ''
|
||||
header /static/CACHE/* Cache-Control "public, max-age=31536000, immutable"
|
||||
|
Loading…
Reference in New Issue
Block a user