diff options
author | IndeedNotJames <git@indeednotjames.com> | 2023-02-24 02:59:30 +0100 |
---|---|---|
committer | IndeedNotJames <git@indeednotjames.com> | 2023-02-24 02:59:30 +0100 |
commit | 7d05a6a910b34c77d549889732840499d987d5f9 (patch) | |
tree | eaef64b99923bfb1670a97a3e08e15ea0ed5c8aa /nixos/tests/gitea.nix | |
parent | ac573e5046f1e2ff60e4260771a88b9862fa7148 (diff) |
nixos/tests/gitea: make gitea package configurable
This allows the same tests to be used for forgejo, a soft-fork of gitea, which currently does not have any tests.
Diffstat (limited to 'nixos/tests/gitea.nix')
-rw-r--r-- | nixos/tests/gitea.nix | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/nixos/tests/gitea.nix b/nixos/tests/gitea.nix index 68a2566c11911..24c84e54fc1db 100644 --- a/nixos/tests/gitea.nix +++ b/nixos/tests/gitea.nix @@ -1,5 +1,6 @@ { system ? builtins.currentSystem, config ? {}, + giteaPackage, pkgs ? import ../.. { inherit system config; } }: @@ -9,7 +10,7 @@ with pkgs.lib; let supportedDbTypes = [ "mysql" "postgres" "sqlite3" ]; makeGiteaTest = type: nameValuePair type (makeTest { - name = "gitea-${type}"; + name = "${giteaPackage.pname}-${type}"; meta.maintainers = with maintainers; [ aanderse kolaente ma27 ]; nodes = { @@ -18,9 +19,10 @@ let services.gitea = { enable = true; database = { inherit type; }; + package = giteaPackage; settings.service.DISABLE_REGISTRATION = true; }; - environment.systemPackages = [ pkgs.gitea pkgs.jq ]; + environment.systemPackages = [ giteaPackage pkgs.jq ]; services.openssh.enable = true; }; client1 = { config, pkgs, ... }: { |