also test buildbot on aarch64-linux
This commit is contained in:
parent
aeffb167fe
commit
d10a73c666
|
@ -1,4 +1,4 @@
|
||||||
{ nixpkgs, system, srvos, buildbot-nix, disko, ... }:
|
{ nixpkgs, system, buildbot-nix, ... }:
|
||||||
let
|
let
|
||||||
# some example configuration to make it eval
|
# some example configuration to make it eval
|
||||||
dummy = { config, modulesPath, ... }: {
|
dummy = { config, modulesPath, ... }: {
|
||||||
|
@ -15,7 +15,7 @@ let
|
||||||
inherit (lib) nixosSystem;
|
inherit (lib) nixosSystem;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
example-master = nixosSystem {
|
"example-master-${system}" = nixosSystem {
|
||||||
inherit system;
|
inherit system;
|
||||||
modules = [
|
modules = [
|
||||||
dummy
|
dummy
|
||||||
|
@ -44,7 +44,7 @@ in
|
||||||
buildbot-nix.nixosModules.buildbot-master
|
buildbot-nix.nixosModules.buildbot-master
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
example-worker = nixosSystem {
|
"example-worker-${system}" = nixosSystem {
|
||||||
inherit system;
|
inherit system;
|
||||||
modules = [
|
modules = [
|
||||||
dummy
|
dummy
|
||||||
|
|
28
flake.nix
28
flake.nix
|
@ -9,28 +9,36 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = inputs@{ self, flake-parts, ... }:
|
outputs = inputs@{ self, flake-parts, ... }:
|
||||||
flake-parts.lib.mkFlake { inherit inputs; } ({ lib, ... }: {
|
flake-parts.lib.mkFlake { inherit inputs; } ({ lib, ... }:
|
||||||
systems = [ "x86_64-linux" ];
|
{
|
||||||
|
systems = [ "x86_64-linux" "aarch64-linux" ];
|
||||||
flake = {
|
flake = {
|
||||||
nixosModules.buildbot-master = ./nix/master.nix;
|
nixosModules.buildbot-master = ./nix/master.nix;
|
||||||
nixosModules.buildbot-worker = ./nix/worker.nix;
|
nixosModules.buildbot-worker = ./nix/worker.nix;
|
||||||
|
|
||||||
nixosConfigurations = import ./examples {
|
nixosConfigurations =
|
||||||
inherit (inputs) nixpkgs srvos disko;
|
let
|
||||||
|
examplesFor = system: import ./examples {
|
||||||
|
inherit system;
|
||||||
|
inherit (inputs) nixpkgs;
|
||||||
buildbot-nix = self;
|
buildbot-nix = self;
|
||||||
system = "x86_64-linux";
|
|
||||||
};
|
};
|
||||||
checks.x86_64-linux = {
|
in
|
||||||
nixos-master = self.nixosConfigurations.example-master.config.system.build.toplevel;
|
examplesFor "x86_64-linux" // examplesFor "aarch64-linux";
|
||||||
nixos-worker = self.nixosConfigurations.example-worker.config.system.build.toplevel;
|
|
||||||
};
|
};
|
||||||
};
|
perSystem = { self', pkgs, system, ... }: {
|
||||||
perSystem = { pkgs, system, ... }: {
|
|
||||||
packages.default = pkgs.mkShell {
|
packages.default = pkgs.mkShell {
|
||||||
packages = [
|
packages = [
|
||||||
pkgs.bashInteractive
|
pkgs.bashInteractive
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
checks =
|
||||||
|
let
|
||||||
|
nixosMachines = lib.mapAttrs' (name: config: lib.nameValuePair "nixos-${name}" config.config.system.build.toplevel) ((lib.filterAttrs (_: config: config.pkgs.system == system)) self.nixosConfigurations);
|
||||||
|
packages = lib.mapAttrs' (n: lib.nameValuePair "package-${n}") self'.packages;
|
||||||
|
devShells = lib.mapAttrs' (n: lib.nameValuePair "devShell-${n}") self'.devShells;
|
||||||
|
in
|
||||||
|
nixosMachines // packages // devShells;
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue