From fb00ef99dbb77b7783c956397e91c99ef405ec55 Mon Sep 17 00:00:00 2001 From: Minijackson Date: Mon, 29 Apr 2024 14:25:28 +0200 Subject: [PATCH] nixos/phoebus-olog: don't automatically enable elasticsearch see #75, #54, follow-up of #60 --- nixos/modules/phoebus/olog.nix | 12 +----------- nixos/tests/phoebus/olog.nix | 7 ++++++- 2 files changed, 7 insertions(+), 12 deletions(-) diff --git a/nixos/modules/phoebus/olog.nix b/nixos/modules/phoebus/olog.nix index 63740dc4..0ac3a078 100644 --- a/nixos/modules/phoebus/olog.nix +++ b/nixos/modules/phoebus/olog.nix @@ -113,18 +113,8 @@ in { # TODO: systemd hardening. Currently level 8.2 EXPOSED }; }; - - services.elasticsearch = { - enable = true; - # Should be kept in sync with the phoebus-alarm-logger and phoebus-save-and-restore services - package = pkgs.elasticsearch7; - }; services.mongodb.enable = true; }; - meta = { - maintainers = with epnixLib.maintainers; [minijackson]; - # TODO: - # doc = ./olog.md; - }; + meta.maintainers = with epnixLib.maintainers; [minijackson]; } diff --git a/nixos/tests/phoebus/olog.nix b/nixos/tests/phoebus/olog.nix index 7adca693..3538ca30 100644 --- a/nixos/tests/phoebus/olog.nix +++ b/nixos/tests/phoebus/olog.nix @@ -7,12 +7,17 @@ meta.maintainers = with epnixLib.maintainers; [minijackson]; nodes = { - server = { + server = {pkgs, ...}: { services.phoebus-olog = { enable = true; settings."demo_auth.enabled" = true; }; + services.elasticsearch = { + enable = true; + package = pkgs.elasticsearch7; + }; + nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [ # Elasticsearch can be used as an SSPL-licensed software, which is