mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-01 15:11:25 +00:00
4ea1d49643
Add also myself as maintainer Add simple test of the nexus service
35 lines
788 B
Nix
35 lines
788 B
Nix
# verifies:
|
|
# 1. nexus service starts on server
|
|
# 2. nexus user can be extended on server
|
|
# 3. nexus service not can startup on server (creating database and all other initial stuff)
|
|
|
|
import ./make-test.nix ({ pkgs, ...} : {
|
|
name = "nexus";
|
|
meta = with pkgs.stdenv.lib.maintainers; {
|
|
maintainers = [ ironpinguin ];
|
|
};
|
|
|
|
nodes = {
|
|
|
|
server =
|
|
{ config, pkgs, ... }:
|
|
{ virtualisation.memorySize = 2048;
|
|
|
|
services.nexus.enable = true;
|
|
|
|
users.extraUsers.nexus.extraGroups = [ "users" ];
|
|
};
|
|
};
|
|
|
|
testScript = ''
|
|
startAll;
|
|
|
|
$server->waitForUnit("nexus");
|
|
|
|
print $server->execute("sudo -u nexus groups");
|
|
$server->mustSucceed("sudo -u nexus groups | grep nexus | grep users");
|
|
|
|
$server->waitForOpenPort(8081);
|
|
'';
|
|
})
|