finish up kiwix
This commit is contained in:
@@ -57,9 +57,12 @@ in {
|
||||
home = cfg.data_dir;
|
||||
createHome = true;
|
||||
group = service;
|
||||
extraGroups = ["archives"];
|
||||
extraGroups = ["media"];
|
||||
};
|
||||
|
||||
# helpful and for scripts
|
||||
environment.systemPackages = with pkgs; [kiwix-tools];
|
||||
|
||||
# enable the ${service} service
|
||||
services.kiwix-serve = {
|
||||
enable = true;
|
||||
@@ -67,7 +70,7 @@ in {
|
||||
port = cfg.port;
|
||||
user = service;
|
||||
group = service;
|
||||
library = cfg.data_dir;
|
||||
libraryPath = "${cfg.data_dir}/library.xml";
|
||||
extraArgs = {
|
||||
};
|
||||
};
|
||||
@@ -91,12 +94,15 @@ in {
|
||||
};
|
||||
|
||||
# add to glance (local service)
|
||||
homelab.glance.links.<category> = [{
|
||||
title = service;
|
||||
url = "https://${cfg.url}";
|
||||
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||
icon = "di:${service}"; }];
|
||||
homelab.glance.links.nomad = [
|
||||
{
|
||||
title = service;
|
||||
url = "https://${cfg.url}";
|
||||
error-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||
check-url = "http://${homelab.host_ip}:${toString cfg.port}";
|
||||
icon = "di:${service}";
|
||||
}
|
||||
];
|
||||
|
||||
# sops.secrets = {
|
||||
# "${service}_" = {
|
||||
|
||||
@@ -77,6 +77,11 @@ in {
|
||||
default = [];
|
||||
description = "list of links for ${service}";
|
||||
};
|
||||
nomad = lib.mkOption {
|
||||
type = lib.types.listOf lib.types.attrs;
|
||||
default = [];
|
||||
description = "list of links for ${service}";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
@@ -244,6 +249,12 @@ in {
|
||||
title = "system";
|
||||
sites = cfg.links.system;
|
||||
}
|
||||
{
|
||||
type = "monitor";
|
||||
cache = "1m";
|
||||
title = "system";
|
||||
sites = cfg.links.nomad;
|
||||
}
|
||||
{
|
||||
type = "custom-api";
|
||||
title = "recpro";
|
||||
|
||||
Reference in New Issue
Block a user