diff --git a/hosts/genepi/default.nix b/hosts/genepi/default.nix index 4d61b1a..92b381a 100644 --- a/hosts/genepi/default.nix +++ b/hosts/genepi/default.nix @@ -15,6 +15,7 @@ ./disk.nix ./dns.nix ./freshrss.nix + ./glance.nix ./hardware.nix ./immich.nix ./monitoring diff --git a/hosts/genepi/dns.nix b/hosts/genepi/dns.nix index 410e874..086bcc0 100644 --- a/hosts/genepi/dns.nix +++ b/hosts/genepi/dns.nix @@ -4,6 +4,7 @@ let genepi = { ip = "100.83.123.79"; subdomains = [ + "glance" "grafana" "images" "rss" diff --git a/hosts/genepi/glance-config.nix b/hosts/genepi/glance-config.nix new file mode 100644 index 0000000..4b913e6 --- /dev/null +++ b/hosts/genepi/glance-config.nix @@ -0,0 +1,187 @@ +{ + theme = { + light = true; + background-color = "0 0 95"; + primary-color = "0 0 10"; + negative-color = "0 90 50"; + }; + pages = [ + { + name = "Home"; + columns = [ + { + size = "small"; + widgets = [ + { + type = "calendar"; + first-day-of-week = "monday"; + } + { + type = "server-stats"; + servers = [ + { + type = "local"; + name = "Genepi"; + } + ]; + } + ]; + } + { + size = "full"; + widgets = [ + { + type = "search"; + autofocus = true; + } + { + type = "monitor"; + cache = "1m"; + title = "Services"; + sites = [ + { + title = "Immich"; + url = "https://images.home.rpqt.fr"; + icon = "si:immich"; + } + { + title = "Grafana"; + url = "https://grafana.home.rpqt.fr"; + icon = "si:grafana"; + } + { + title = "FreshRSS"; + url = "https://rss.home.rpqt.fr"; + icon = "si:rss"; + } + ]; + } + ]; + } + { + size = "small"; + widgets = [ + { + type = "weather"; + location = "Grenoble, France"; + units = "metric"; + hour-format = "24h"; + } + ]; + } + ]; + } + { + name = "Feeds"; + columns = [ + { + size = "small"; + widgets = [ + { + type = "rss"; + title = "Blogs"; + limit = 10; + collapse-after = 5; + cache = "12h"; + feeds = [ + { + url = "https://rss.home.rpqt.fr/api/query.php?user=rpqt&t=74HfeLZ6Wu9h4MmjNR38Rz&f=rss"; + } + ]; + } + { + type = "rss"; + title = "Status & Updates"; + limit = 3; + cache = "12h"; + feeds = [ + { + url = "https://status.sr.ht/index.xml"; + } + ]; + } + ]; + } + { + size = "full"; + widgets = [ + { + type = "group"; + widgets = [ + { + type = "hacker-news"; + } + { + type = "lobsters"; + } + ]; + } + { + type = "group"; + widgets = [ + { + type = "reddit"; + subreddit = "selfhosted"; + show-thumbnails = true; + } + { + type = "reddit"; + subreddit = "homelab"; + show-thumbnails = true; + } + ]; + } + { + type = "videos"; + channels = [ + "UCR-DXc1voovS8nhAvccRZhg" + "UCsBjURrPoezykLs9EqgamOA" + ]; + } + ]; + } + { + size = "small"; + widgets = [ + { + type = "releases"; + cache = "1d"; + repositories = [ + "glanceapp/glance" + ]; + } + { + type = "custom-api"; + title = "Random Fact"; + cache = "6h"; + url = "https://uselessfacts.jsph.pl/api/v2/facts/random"; + template = '' +
{{ .JSON.String "text" }}
+ ''; + } + { + type = "custom-api"; + title = "Steam Specials"; + cache = "12h"; + url = "https://store.steampowered.com/api/featuredcategories?cc=us"; + template = '' +