Skip to content

Commit 361ead8

Browse files
committed
[DDW-1151] Use hydraJobs in flake.nix instead of release.nix – Cicero instead of deprecated Hydra
1 parent fcce514 commit 361ead8

File tree

6 files changed

+69
-86
lines changed

6 files changed

+69
-86
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Changelog
22

3+
## vNext
4+
5+
### Chores
6+
7+
- Switched from Hydra’s `release.nix` to Cicero’s `flake.nix` ([PR 3060](https://github.com/input-output-hk/daedalus/pull/3060))
8+
39
## 5.1.0
410

511
### Chores

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ Daedalus - Cryptocurrency Wallet
3838
trusted-users = root
3939
allowed-users = *
4040
41-
substituters = https://hydra.iohk.io https://cache.nixos.org/
41+
substituters = https://cache.iog.io https://cache.nixos.org/
4242
trusted-substituters =
4343
trusted-public-keys = hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ= cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
4444
extra-sandbox-paths = /System/Library/Frameworks /System/Library/PrivateFrameworks /usr/lib

default.nix

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{ target ? builtins.currentSystem
2+
, localLibSystem ? builtins.currentSystem
23
, nodeImplementation ? "cardano"
3-
, localLib ? import ./lib.nix { inherit nodeImplementation; }
4+
, localLib ? import ./lib.nix { inherit nodeImplementation; system = localLibSystem; }
45
, cluster ? "mainnet"
56
, version ? "versionNotSet"
67
, buildNum ? null

flake.nix

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
{
2+
description = "Cicero jobs populating https://cache.iog.io – this cannot yet build Daedalus";
3+
inputs = {};
4+
outputs = inputs: {
5+
hydraJobs = {
6+
7+
# --- Linux ----------------------------------------------------
8+
x86_64-linux = let
9+
d = import ./default.nix { target = "x86_64-linux"; localLibSystem = "x86_64-linux"; };
10+
in {
11+
cardano-bridge = d.daedalus-bridge;
12+
cardano-node = d.cardano-node;
13+
# daedalus = d.daedalus; # TODO: I’m really not sure if it still makes sense, if we have Buildkite…
14+
daedalus-installer = d.daedalus-installer;
15+
devShellGCRoot = (import ./shell.nix { system = "x86_64-linux"; autoStartBackend = true; }).gcRoot;
16+
mono = d.pkgs.mono;
17+
nodejs = d.nodejs;
18+
tests = d.tests;
19+
wine = d.wine;
20+
wine64 = d.wine64;
21+
yaml2json = d.yaml2json;
22+
};
23+
# --------------------------------------------------------------
24+
25+
# --- Windows (x-compiled from Linux) --------------------------
26+
x86_64-windows = let
27+
d = import ./default.nix { target = "x86_64-windows"; localLibSystem = "x86_64-linux"; };
28+
in {
29+
cardano-bridge = d.daedalus-bridge;
30+
cardano-node = d.cardano-node;
31+
};
32+
# --------------------------------------------------------------
33+
34+
# --- Darwin ---------------------------------------------------
35+
x86_64-darwin = let
36+
d = import ./default.nix { target = "x86_64-darwin"; localLibSystem = "x86_64-darwin"; };
37+
in {
38+
cardano-bridge = d.daedalus-bridge;
39+
cardano-node = d.cardano-node;
40+
daedalus-installer = d.daedalus-installer;
41+
devShellGCRoot = (import ./shell.nix { system = "x86_64-darwin"; autoStartBackend = true; }).gcRoot;
42+
nodejs = d.nodejs;
43+
yaml2json = d.yaml2json;
44+
};
45+
# --------------------------------------------------------------
46+
47+
};
48+
};
49+
# --- Flake Local Nix Configuration ----------------------------
50+
nixConfig = {
51+
extra-substituters = ["https://cache.iog.io" "https://iog.cachix.org"];
52+
extra-trusted-public-keys = ["hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ=" "iog.cachix.org-1:nYO0M9xTk/s5t1Bs9asZ/Sww/1Kt/hRhkLP0Hhv/ctY="];
53+
allow-import-from-derivation = "true";
54+
};
55+
# --------------------------------------------------------------
56+
}

lib.nix

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
1-
{ nodeImplementation ? "cardano" }:
1+
{ nodeImplementation ? "cardano"
2+
, system ? builtins.currentSystem
3+
}:
24

35
let
46
sources = import ./nix/sources.nix;
57
iohkNix = import sources.iohk-nix { sourcesOverride = sources; };
6-
nixpkgs = import sources.nixpkgs { sourcesOverride = sources; };
8+
nixpkgs = import sources.nixpkgs { sourcesOverride = sources; inherit system; };
79
# TODO: can we use the filter in iohk-nix instead?
810
cleanSourceFilter = with pkgs.stdenv;
911
name: type: let baseName = baseNameOf (toString name); in ! (

release.nix

Lines changed: 0 additions & 82 deletions
This file was deleted.

0 commit comments

Comments
 (0)