From d1d58d414104b190ebdcab6f92e2adc3d2f1a19a Mon Sep 17 00:00:00 2001 From: Johann Wagner Date: Wed, 7 Aug 2024 12:40:55 +0200 Subject: [PATCH] nixos/tests/librenms: Adding db seed to have admin role --- nixos/tests/librenms.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/nixos/tests/librenms.nix b/nixos/tests/librenms.nix index 5a32b62e1409..14035a01ce87 100644 --- a/nixos/tests/librenms.nix +++ b/nixos/tests/librenms.nix @@ -50,6 +50,9 @@ in API_USER_NAME=api API_TOKEN=${api_token} # random md5 hash + # seeding database to get the admin roles + ${pkgs.librenms}/artisan db:seed --force --no-interaction + # we don't need to know the password, it just has to exist API_USER_PASS=$(${pkgs.pwgen}/bin/pwgen -s 64 1) ${pkgs.librenms}/artisan user:add $API_USER_NAME -r admin -p $API_USER_PASS