diff --git a/assets/logo_crans_dark.png b/assets/logo_crans_dark.png new file mode 100644 index 0000000..545b60f Binary files /dev/null and b/assets/logo_crans_dark.png differ diff --git a/hosts/physiques/zamok/info.nix b/hosts/physiques/zamok/info.nix index 3237c2d..bc875a8 100644 --- a/hosts/physiques/zamok/info.nix +++ b/hosts/physiques/zamok/info.nix @@ -20,4 +20,124 @@ id = 54; switch.salameche = 14; }; + + gatus.endpoints = [{ + name = "Zamok"; + url = "icmp://zamok.crans.org"; + group = "Crans"; + interval = "1m"; + conditions = [ + "[CONNECTED] == true" + ]; + } + { + name = "Page Personnelles"; + url = "https://perso.crans.org/club-krobot/"; + group = "Crans"; + interval = "1m"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } + + + +{ + name = "Mail principal"; + url = "tcp://185.230.79.39:25"; + group = "Crans"; + interval = "1m"; + conditions = [ + "[CONNECTED] == true" + "[RESPONSE_TIME] < 300"]; + } + +{ + name = "DNS Principal"; + url = "185.230.79.9"; + group = "Crans"; + dns.query-type = "A"; + dns.query-name = "crans.org"; + interval = "1m"; + conditions = [ + "[CONNECTED] == true" + "[DNS_RCODE] == NOERROR"]; + } + + { + name = "WebMail"; + url = "https://roundcube.crans.org/"; + interval = "1m"; + group = "Crans"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } +{ + name = "GitLab"; + url = "https://gitlab.crans.org/"; + interval = "1m"; + group = "Crans"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } + + +{ + name = "Listes de diffusions"; + url = "https://Stop:Spam@lists.crans.org/postorius/lists/?all-lists"; + interval = "1m"; + group = "Crans"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } + +{ + name = "Pad"; + url = "https://pad.crans.org/"; + interval = "1m"; + group = "Crans"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } +{ + name = "PDF"; + url = "https://pdf.crans.org/"; + interval = "1m"; + group = "Crans"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } +{ + name = "Framadate"; + url = "https://framadate.crans.org/"; + interval = "1m"; + group = "Crans"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } +{ + name = "Ethercalc"; + url = "https://ethercalc.crans.org/"; + interval = "1m"; + group = "Crans"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } +{ + name = "ZeroBin"; + url = "https://zero.crans.org/"; + interval = "1m"; + group = "Crans"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } + ]; } diff --git a/hosts/vm/imprimante/info.nix b/hosts/vm/imprimante/info.nix new file mode 100644 index 0000000..7433107 --- /dev/null +++ b/hosts/vm/imprimante/info.nix @@ -0,0 +1,19 @@ +{ + name = "imprimante"; + description = "Serveur des impressions crans"; + id = 0; + + isDebian = true; + + gatus.endpoints = [ + { + name = "printer"; + url = "https://imprimante.crans.org/"; + interval = "1m"; + group = "Crans"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } + ] +} diff --git a/hosts/vm/jitsi/info.nix b/hosts/vm/jitsi/info.nix index f070613..0ce6e18 100644 --- a/hosts/vm/jitsi/info.nix +++ b/hosts/vm/jitsi/info.nix @@ -22,4 +22,16 @@ public-ssh = ""; + gatus.endpoints = [ + { + name = "Jitsi"; + url = "https://jitsi.crans.org/"; + interval = "1m"; + group = "Crans"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } + ] + } diff --git a/hosts/vm/mediakiwi/info.nix b/hosts/vm/mediakiwi/info.nix index 3097f89..408df87 100644 --- a/hosts/vm/mediakiwi/info.nix +++ b/hosts/vm/mediakiwi/info.nix @@ -10,4 +10,16 @@ }; resticClient.when = "06:47"; + + gatus.endpoints = [ + { + name = "MediaWiki"; + url = "https://mediawiki.crans.org/"; + interval = "1m"; + group = "Crans"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } + ]; } diff --git a/hosts/vm/nextcloud/info.nix b/hosts/vm/nextcloud/info.nix index 598f79a..8e339be 100644 --- a/hosts/vm/nextcloud/info.nix +++ b/hosts/vm/nextcloud/info.nix @@ -19,4 +19,14 @@ homeAdh.enable = true; resticClient.enable = false; + + gatus.endpoints = [{ + name = "NextCloud"; + url = "https://nextcloud.crans.org/"; + interval = "1m"; + group = "Crans"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + }] } diff --git a/hosts/vm/periodique/info.nix b/hosts/vm/periodique/info.nix index 489eaff..a260bdd 100644 --- a/hosts/vm/periodique/info.nix +++ b/hosts/vm/periodique/info.nix @@ -10,4 +10,17 @@ }; resticClient.when = "02:56"; + + gatus.endpoints = [ + { + name = "Element"; + url = "https://element.crans.org/"; + interval = "1m"; + group = "Crans"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } + ] + } diff --git a/hosts/vm/perseverance/info.nix b/hosts/vm/perseverance/info.nix index 0fbd964..155a11d 100644 --- a/hosts/vm/perseverance/info.nix +++ b/hosts/vm/perseverance/info.nix @@ -15,4 +15,34 @@ users.root.passwordFile = ../../../secrets/apprentix/root.age; resticClient.enable = false; + + gatus.endpoints = [{ + name = "Serveur Med"; + url = "https://med.crans.org/"; + interval = "1m"; + group = "Associations"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } + { + name = "Serveur Photo LENS"; + url = "https://photos.crans.org/"; + interval = "1m"; + group = "Associations"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } + { + name = "Note BDE"; + url = "https://note.crans.org/"; + interval = "1m"; + group = "Associations"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } + + ] } diff --git a/hosts/vm/perseverance/perseverance.nix b/hosts/vm/perseverance/perseverance.nix index 459ebbf..7204557 100644 --- a/hosts/vm/perseverance/perseverance.nix +++ b/hosts/vm/perseverance/perseverance.nix @@ -3,6 +3,7 @@ let cfg = config.services.forgejo; srv = cfg.settings.server; + endpoints = in { services.openssh.settings.AcceptEnv = [ "GIT_PROTOCOL" ]; @@ -21,4 +22,25 @@ in }; }; }; + + + services.gatus = { + enable = true; + openFirewall = false; + settings = { + web.port = 8080; + ui.title = "Page Status Crans"; + ui.description = "Show all Status for Crans infrasctructure"; + ui.dashboard-heading = "Crans Status"; + ui.dashboard-subheading = "Monitor the health of Crans endpoints in real-time"; + ui.header = "Crans"; + ui.logo = ../../../assets/logo_crans_dark.png ; + ui.favicon.default = ../../../assets/logo_crans_dark.png ; + ui.link = "https://crans.org"; + storage.type = "sqlite"; + storage.path = "gatus.db"; + endpoints = gatus.endpoints; + + }; + }; } diff --git a/hosts/vm/reverseproxy/info.nix b/hosts/vm/reverseproxy/info.nix index e2bcf3f..c46132a 100644 --- a/hosts/vm/reverseproxy/info.nix +++ b/hosts/vm/reverseproxy/info.nix @@ -16,4 +16,16 @@ resticClient.when = "03:42"; + gatus.endpoints = [ + { + name = "Crans.org"; + url = "https://crans.org/"; + interval = "1m"; + group = "Crans"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } + ] + } diff --git a/hosts/vm/vaultwarden/info.nix b/hosts/vm/vaultwarden/info.nix index 1cf8489..f8f95f8 100644 --- a/hosts/vm/vaultwarden/info.nix +++ b/hosts/vm/vaultwarden/info.nix @@ -10,4 +10,16 @@ }; resticClient.when = "04:44"; + + gatus.endpoints = [ + { + name = "VaultWarden"; + url = "https://vaultwarden.crans.org/"; + group = "Crans"; + interval = "1m"; + conditions = [ + "[STATUS] == 200" + "[RESPONSE_TIME] < 300"]; + } + ] }