Remove Homepage Dashboard
All checks were successful
/ check (push) Successful in 39s

Signed-off-by: Oliver Davies <oliver@oliverdavies.uk>
This commit is contained in:
Oliver Davies 2025-11-05 00:02:10 +00:00
parent 6bf7a5f97a
commit 239fb86c5d
14 changed files with 0 additions and 331 deletions

View file

@ -9,7 +9,6 @@
services = {
audiobookshelf.enable = true;
home-assistant.enable = true;
homepage-dashboard.enable = true;
freshrss.enable = true;
paperless.enable = true;
peertube.enable = true;

View file

@ -15,26 +15,6 @@ in
default = "audiobookshelf.${homelab.domain}";
type = types.str;
};
homepage.name = mkOption {
default = "Audiobookshelf";
type = types.str;
};
homepage.description = mkOption {
default = "Self-hosted audiobook and podcast server";
type = types.str;
};
homepage.icon = mkOption {
default = "audiobookshelf";
type = types.str;
};
homepage.category = mkOption {
default = "Media";
type = types.str;
};
};
config = mkIf cfg.enable {

View file

@ -23,26 +23,6 @@ in
default = "${service}.${homelab.domain}";
type = types.str;
};
homepage.name = mkOption {
default = "Tube Archivist";
type = types.str;
};
homepage.description = mkOption {
default = "Your self hosted YouTube media server";
type = types.str;
};
homepage.icon = mkOption {
default = "tube-archivist";
type = types.str;
};
homepage.category = mkOption {
default = "Media";
type = types.str;
};
};
config = mkIf cfg.enable {

View file

@ -15,26 +15,6 @@ in
default = "home.${homelab.domain}";
type = types.str;
};
homepage.name = mkOption {
default = "Home Assisant";
type = types.str;
};
homepage.description = mkOption {
default = "Open source home automation that puts local control and privacy first.";
type = types.str;
};
homepage.icon = mkOption {
default = "home-assistant";
type = types.str;
};
homepage.category = mkOption {
default = "Services";
type = types.str;
};
};
config = mkIf cfg.enable {

View file

@ -15,26 +15,6 @@ in
default = "${service}.${homelab.domain}";
type = types.str;
};
homepage.name = mkOption {
default = "Paperless-ngx";
type = types.str;
};
homepage.description = mkOption {
default = "Document management system";
type = types.str;
};
homepage.icon = mkOption {
default = "paperless";
type = types.str;
};
homepage.category = mkOption {
default = "Services";
type = types.str;
};
};
config = mkIf cfg.enable {

View file

@ -25,26 +25,6 @@ in
default = "videos.${homelab.domain}";
type = types.str;
};
homepage.name = mkOption {
default = "Peertube";
type = types.str;
};
homepage.description = mkOption {
default = "A free and open-source, decentralized, ActivityPub federated video platform";
type = types.str;
};
homepage.icon = mkOption {
default = "peertube";
type = types.str;
};
homepage.category = mkOption {
default = "Media";
type = types.str;
};
};
config = mkIf cfg.enable {

View file

@ -10,7 +10,6 @@ in
};
config.homelab.ports = {
homepage-dashboard = 8097;
mealie = 9001;
pihole = 8082;
tubearchivist = 8099;

View file

@ -7,7 +7,6 @@
{
imports = [
./homepage
./mealie.nix
./samba.nix
./uptime-kuma.nix

View file

@ -1,63 +0,0 @@
{ config, lib, ... }:
with lib;
let
cfg = homelab.services.${service};
homelab = config.homelab;
service = "homepage-dashboard";
in
{
options.homelab.services.${service} = {
enable = mkEnableOption "Enable ${service}";
url = mkOption {
default = "${config.networking.hostName}.${homelab.domain}";
type = types.str;
};
};
config = mkIf cfg.enable {
services = {
${service} = {
enable = true;
listenPort = homelab.ports.${service};
openFirewall = true;
customCSS = ''
#information-widgets {
padding-left: 1.5rem;
padding-right: 1.5rem;
}
div#footer {
display: none;
}
.services-group {
margin-bottom: 3rem;
}
'';
services = (import ./services.nix { inherit config lib; });
settings = {
headerStyle = "clean";
hideVersion = "true";
layout = (import ./layout.nix);
statusStyle = "dot";
};
};
glances.enable = true;
nginx.virtualHosts.${cfg.url} = {
forceSSL = true;
useACMEHost = homelab.domain;
locations."/".proxyPass =
"http://localhost:${toString config.services.homepage-dashboard.listenPort}";
};
};
};
}

View file

@ -1,57 +0,0 @@
{ config }:
{
Glances =
let
port = toString config.services.glances.port;
in
[
{
Info = {
widget = {
type = "glances";
url = "http://localhost:${port}";
metric = "info";
chart = false;
version = 4;
};
};
}
{
"CPU Temp" = {
widget = {
type = "glances";
url = "http://localhost:${port}";
metric = "sensor:Package id 0";
chart = false;
version = 4;
};
};
}
{
Processes = {
widget = {
type = "glances";
url = "http://localhost:${port}";
metric = "process";
chart = false;
version = 4;
};
};
}
{
Network = {
widget = {
type = "glances";
url = "http://localhost:${port}";
metric = "network:enp0s20f0u1";
chart = false;
version = 4;
};
};
}
];
}

View file

@ -1,23 +0,0 @@
[
{
Glances = {
columns = 4;
header = false;
style = "row";
};
}
{
Media = {
header = true;
style = "column";
};
}
{
Services = {
header = true;
style = "column";
};
}
]

View file

@ -1,32 +0,0 @@
{ config, lib }:
with lib;
let
homelab = config.homelab.services;
homepageCategories = [
"Media"
"Services"
];
homepageServices =
category:
(attrsets.filterAttrs (
name: value: value ? homepage && value.homepage.category == category
) homelab);
services = lists.forEach homepageCategories (cat: {
"${cat}" =
lib.lists.forEach (lib.attrsets.mapAttrsToList (name: value: name) (homepageServices "${cat}"))
(x: {
"${homelab.${x}.homepage.name}" = {
icon = homelab.${x}.homepage.icon;
description = homelab.${x}.homepage.description;
href = "https://${homelab.${x}.url}";
siteMonitor = "https://${homelab.${x}.url}";
};
});
});
in
services ++ [ (import ./glances.nix { inherit config; }) ]

View file

@ -15,26 +15,6 @@ in
default = "uptime.${homelab.domain}";
type = types.str;
};
homepage.name = mkOption {
default = "Uptime Kuma";
type = types.str;
};
homepage.description = mkOption {
default = "A fancy self-hosted monitoring tool";
type = types.str;
};
homepage.icon = mkOption {
default = "uptime-kuma";
type = types.str;
};
homepage.category = mkOption {
default = "Services";
type = types.str;
};
};
config = mkIf cfg.enable {

View file

@ -1,39 +1,6 @@
return {
s("home_packages", fmta("home.packages = with pkgs; [ <> ];", i(0))),
s(
"homepage_options",
fmta(
[[
homepage.name = mkOption {
default = "<name>";
type = types.str;
};
homepage.description = mkOption {
default = "<description>";
type = types.str;
};
homepage.icon = mkOption {
default = "<icon>";
type = types.str;
};
homepage.category = mkOption {
default = "<finish>";
type = types.str;
};
]],
{
description = i(2),
finish = i(0),
icon = i(3),
name = i(1),
}
)
),
s(
"imports",
fmta(