ci: moved to tasks

This commit is contained in:
kat witch 2021-05-13 18:32:46 +01:00
parent f85f0e8f24
commit 3a5997cac0
No known key found for this signature in database
GPG key ID: 1B477797DCA5EC72
2 changed files with 15 additions and 15 deletions

View file

@ -21,15 +21,6 @@ jobs:
with:
attrs: ci.run.bootstrap
quiet: false
- id: host-athame
name: build host/athame
run: nix build -Lf . hosts.athame.config.system.build.toplevel --show-trace
- id: host-samhain
name: build host/samhain
run: nix build -Lf . hosts.samhain.config.system.build.toplevel --show-trace
- id: host-yule
name: build host/yule
run: nix build -Lf . hosts.yule.config.system.build.toplevel --show-trace
- id: ci-dirty
name: nix test dirty
uses: arcnmx/ci/actions/nix/run@master

19
ci.nix
View file

@ -1,13 +1,22 @@
{ lib, ... }: with lib; {
{ lib, channels, ... }: with lib; {
name = "nixfiles";
ci.gh-actions.enable = true;
ci.gh-actions.export = true;
gh-actions.jobs.ci.step = let
hostnames = [ "samhain" "yule" "athame"];
tasks = let hostnames = [ "samhain" "yule" "athame" ];
in mapAttrs' (k: nameValuePair "host-${k}") (genAttrs hostnames (host: {
name = "build host/${host}";
run = "nix build -Lf . hosts.${host}.config.system.build.toplevel --show-trace";
inputs = with channels.cipkgs; ci.command {
name = "build-${host}";
displayName = "build hosts/${host}";
nativeBuildInputs = [ nix ];
command = ''
nix build -Lf . hosts.${host}.config.system.build.toplevel --show-trace --no-link
nix-collect-garbage
'';
impure = true;
};
}));
ci.gh-actions.checkoutOptions.submodules = false;
cache.cachix.arc = {
enable = true;