add radicle-explorer module, and enable it on Cape
This commit is contained in:
parent
6632dde007
commit
975bf38dc2
8 changed files with 42 additions and 1 deletions
|
|
@ -28,6 +28,7 @@
|
|||
caddy = {
|
||||
enable = true;
|
||||
baseDomain = "youthlic.fun";
|
||||
radicle-explorer.enable = true;
|
||||
};
|
||||
juicity.server.enable = true;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -5,6 +5,9 @@
|
|||
}: let
|
||||
cfg = config.youthlic.programs.caddy;
|
||||
in {
|
||||
imports = [
|
||||
./radicle-explorer.nix
|
||||
];
|
||||
options = {
|
||||
youthlic.programs.caddy = {
|
||||
enable = lib.mkEnableOption "caddy";
|
||||
27
nixos/modules/programs/caddy/radicle-explorer.nix
Normal file
27
nixos/modules/programs/caddy/radicle-explorer.nix
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
cfg = config.youthlic.programs.caddy.radicle-explorer;
|
||||
caddy-cfg = config.youthlic.programs.caddy;
|
||||
in {
|
||||
options = {
|
||||
youthlic.programs.caddy.radicle-explorer = {
|
||||
enable = lib.mkEnableOption "caddy.radicle-explorer";
|
||||
};
|
||||
};
|
||||
config = lib.mkIf (cfg.enable && caddy-cfg.enable) {
|
||||
services.caddy.virtualHosts = {
|
||||
"radicle.${caddy-cfg.baseDomain}" = {
|
||||
extraConfig = ''
|
||||
root * ${pkgs.radicle-explorer}
|
||||
encode zstd gzip
|
||||
try_files {path} /index.html
|
||||
file_server
|
||||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -7,7 +7,7 @@
|
|||
./transfer-sh.nix
|
||||
./rustypaste
|
||||
./mautrix-telegram.nix
|
||||
./caddy.nix
|
||||
./caddy
|
||||
./dae
|
||||
./forgejo.nix
|
||||
./kanata.nix
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ in
|
|||
./dae.nix
|
||||
./jujutsu.nix
|
||||
./spotifyx.nix
|
||||
./radicle-explorer.nix
|
||||
]
|
||||
|> map (file: import file args)
|
||||
|> (overlays: (lib.composeManyExtensions overlays) final prev)
|
||||
|
|
|
|||
5
overlays/modifications/radicle-explorer.nix
Normal file
5
overlays/modifications/radicle-explorer.nix
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
{outputs, ...}: final: prev: let
|
||||
inherit (prev.stdenv.hostPlatform) system;
|
||||
in {
|
||||
radicle-explorer = outputs.packages."${system}".radicle-explorer;
|
||||
}
|
||||
|
|
@ -13,6 +13,7 @@ in
|
|||
rime-ice = callPackage ./rime-ice.nix {};
|
||||
dioxionary = callPackage ./dioxionary.nix {};
|
||||
spotifyx = callPackage ./spotifyx.nix {};
|
||||
radicle-explorer = callPackage ./radicle-explorer.nix {};
|
||||
|
||||
noto-serif-cjk = callPackage ./noto-serif-cjk.nix {};
|
||||
noto-sans-cjk = callPackage ./noto-sans-cjk.nix {};
|
||||
|
|
|
|||
3
pkgs/radicle-explorer.nix
Normal file
3
pkgs/radicle-explorer.nix
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
{pkgs, ...}:
|
||||
pkgs.radicle-explorer.withConfig {
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue