forked from input-output-hk/cardano-ops
-
Notifications
You must be signed in to change notification settings - Fork 0
/
release.nix
58 lines (47 loc) · 1.52 KB
/
release.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
############################################################################
#
# Hydra release jobset.
#
# The purpose of this file is to select jobs defined in default.nix and map
# them to all supported build platforms.
#
############################################################################
# The project sources
{ cardano-ops ? { outPath = ./.; rev = "abcdef"; }
# Function arguments to pass to the project
, projectArgs ? { inherit sourcesOverride; config = { allowUnfree = false; inHydra = true; }; }
# The systems that the jobset will be built for.
, supportedSystems ? [ "x86_64-linux" "x86_64-darwin" ]
# The systems used for cross-compiling
, supportedCrossSystems ? [ "x86_64-linux" ]
# A Hydra option
, scrubJobs ? true
# Import pkgs
, pkgs ? import ./nix { inherit sourcesOverride; }
}:
with import pkgs.iohkNix.release-lib {
inherit pkgs;
inherit supportedSystems supportedCrossSystems scrubJobs projectArgs;
packageSet = import ops-lib;
gitrev = ops-lib.rev;
};
with pkgs.lib;
let
jobs = {
native = mapTestOn (packagePlatforms project);
}
// {
# This aggregate job is what IOHK Hydra uses to update
# the CI status in GitHub.
required = mkRequiredJob (
# project executables:
[ jobs.native.nixops.x86_64-linux
jobs.native.nginxStable.x86_64-linux
jobs.native.nginxMainline.x86_64-linux
]
);
}
# Build the shell derivation in Hydra so that all its dependencies
# are cached.
// mapTestOn (packagePlatforms { inherit (project) shell; });
in jobs