Merge pull request #217890 from IndeedNotJames/nixos-tests-gitea
nixos/tests/gitea: open up test for forgejo
This commit is contained in:
commit
eb03dde70d
3 changed files with 10 additions and 4 deletions
|
@ -228,6 +228,7 @@ in {
|
||||||
fluentd = handleTest ./fluentd.nix {};
|
fluentd = handleTest ./fluentd.nix {};
|
||||||
fluidd = handleTest ./fluidd.nix {};
|
fluidd = handleTest ./fluidd.nix {};
|
||||||
fontconfig-default-fonts = handleTest ./fontconfig-default-fonts.nix {};
|
fontconfig-default-fonts = handleTest ./fontconfig-default-fonts.nix {};
|
||||||
|
forgejo = handleTest ./gitea.nix { giteaPackage = pkgs.forgejo; };
|
||||||
freenet = handleTest ./freenet.nix {};
|
freenet = handleTest ./freenet.nix {};
|
||||||
freeswitch = handleTest ./freeswitch.nix {};
|
freeswitch = handleTest ./freeswitch.nix {};
|
||||||
freshrss-sqlite = handleTest ./freshrss-sqlite.nix {};
|
freshrss-sqlite = handleTest ./freshrss-sqlite.nix {};
|
||||||
|
@ -241,7 +242,7 @@ in {
|
||||||
geth = handleTest ./geth.nix {};
|
geth = handleTest ./geth.nix {};
|
||||||
ghostunnel = handleTest ./ghostunnel.nix {};
|
ghostunnel = handleTest ./ghostunnel.nix {};
|
||||||
gitdaemon = handleTest ./gitdaemon.nix {};
|
gitdaemon = handleTest ./gitdaemon.nix {};
|
||||||
gitea = handleTest ./gitea.nix {};
|
gitea = handleTest ./gitea.nix { giteaPackage = pkgs.gitea; };
|
||||||
gitlab = handleTest ./gitlab.nix {};
|
gitlab = handleTest ./gitlab.nix {};
|
||||||
gitolite = handleTest ./gitolite.nix {};
|
gitolite = handleTest ./gitolite.nix {};
|
||||||
gitolite-fcgiwrap = handleTest ./gitolite-fcgiwrap.nix {};
|
gitolite-fcgiwrap = handleTest ./gitolite-fcgiwrap.nix {};
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
{ system ? builtins.currentSystem,
|
{ system ? builtins.currentSystem,
|
||||||
config ? {},
|
config ? {},
|
||||||
|
giteaPackage,
|
||||||
pkgs ? import ../.. { inherit system config; }
|
pkgs ? import ../.. { inherit system config; }
|
||||||
}:
|
}:
|
||||||
|
|
||||||
|
@ -9,8 +10,8 @@ with pkgs.lib;
|
||||||
let
|
let
|
||||||
supportedDbTypes = [ "mysql" "postgres" "sqlite3" ];
|
supportedDbTypes = [ "mysql" "postgres" "sqlite3" ];
|
||||||
makeGiteaTest = type: nameValuePair type (makeTest {
|
makeGiteaTest = type: nameValuePair type (makeTest {
|
||||||
name = "gitea-${type}";
|
name = "${giteaPackage.pname}-${type}";
|
||||||
meta.maintainers = with maintainers; [ aanderse kolaente ma27 ];
|
meta.maintainers = with maintainers; [ aanderse indeednotjames kolaente ma27 ];
|
||||||
|
|
||||||
nodes = {
|
nodes = {
|
||||||
server = { config, pkgs, ... }: {
|
server = { config, pkgs, ... }: {
|
||||||
|
@ -18,9 +19,10 @@ let
|
||||||
services.gitea = {
|
services.gitea = {
|
||||||
enable = true;
|
enable = true;
|
||||||
database = { inherit type; };
|
database = { inherit type; };
|
||||||
|
package = giteaPackage;
|
||||||
settings.service.DISABLE_REGISTRATION = true;
|
settings.service.DISABLE_REGISTRATION = true;
|
||||||
};
|
};
|
||||||
environment.systemPackages = [ pkgs.gitea pkgs.jq ];
|
environment.systemPackages = [ giteaPackage pkgs.jq ];
|
||||||
services.openssh.enable = true;
|
services.openssh.enable = true;
|
||||||
};
|
};
|
||||||
client1 = { config, pkgs, ... }: {
|
client1 = { config, pkgs, ... }: {
|
||||||
|
|
|
@ -10,6 +10,7 @@
|
||||||
, lib
|
, lib
|
||||||
, makeWrapper
|
, makeWrapper
|
||||||
, nix
|
, nix
|
||||||
|
, nixosTests
|
||||||
, openssh
|
, openssh
|
||||||
, pam
|
, pam
|
||||||
, pamSupport ? true
|
, pamSupport ? true
|
||||||
|
@ -65,6 +66,8 @@ buildGoModule rec {
|
||||||
--prefix PATH : ${lib.makeBinPath [ bash git gzip openssh ]}
|
--prefix PATH : ${lib.makeBinPath [ bash git gzip openssh ]}
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
passthru.tests = nixosTests.forgejo;
|
||||||
|
|
||||||
passthru.updateScript = lib.getExe (writeShellApplication {
|
passthru.updateScript = lib.getExe (writeShellApplication {
|
||||||
name = "update-forgejo";
|
name = "update-forgejo";
|
||||||
runtimeInputs = [
|
runtimeInputs = [
|
||||||
|
|
Loading…
Reference in a new issue