Skip to content
This repository has been archived by the owner on Aug 18, 2020. It is now read-only.

Commit

Permalink
Merge #4252
Browse files Browse the repository at this point in the history
4252: Mainnet CI prerequisites, round II (final) r=disassembler a=deepfire

1. `iohk-nix` bumped to version compatible with latest `cardano-byron-proxy`
1. `network-transport-tcp` bumped to version which fixes IntersectMBO/cardano-node#296
1. Convenience shells in some component dirs.

Co-authored-by: Kosyrev Serge <serge.kosyrev@iohk.io>
Co-authored-by: Alexander Vieth <aovieth@gmail.com>
Co-authored-by: Samuel Leathers <samuel.leathers@iohk.io>
  • Loading branch information
4 people authored Nov 22, 2019
2 parents c63554b + d0cc2e6 commit 5d0a227
Show file tree
Hide file tree
Showing 14 changed files with 241 additions and 183 deletions.
6 changes: 6 additions & 0 deletions crypto/shell.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
let
self = import ../. {};
in (self.nix-tools.shellFor {
name = "cardano-sl-crypto";
packages = ps: [ ps.cardano-sl-crypto ps.cabal-install ];
})
33 changes: 13 additions & 20 deletions lib.nix
Original file line number Diff line number Diff line change
@@ -1,30 +1,23 @@
let
# Allow overriding pinned nixpkgs for debugging purposes via cardano_pkgs
# Imports the iohk-nix library.
# The version can be overridden for debugging purposes by setting
# NIX_PATH=iohk_nix=/path/to/iohk-nix
iohkNix = import (
let try = builtins.tryEval <iohk_nix>;
in if try.success
then builtins.trace "using host <iohk_nix>" try.value
else
let
spec = builtins.fromJSON (builtins.readFile ./nix/iohk-nix-src.json);
in builtins.fetchTarball {
url = "${spec.url}/archive/${spec.rev}.tar.gz";
inherit (spec) sha256;
}) {};
# Gets the value of an environment variable, with a default if it's
# unset or empty.
sources = import ./nix/sources.nix;
pkgs' = import sources.nixpkgs {};
haskellNixJson = let
src = sources."haskell.nix";
in __toJSON {
inherit (sources."haskell.nix") rev sha256;
url = "https://github.com/${src.owner}/${src.repo}";
};
iohkNix = import sources.iohk-nix { haskellNixJsonOverride = pkgs'.writeText "haskell-nix.json" haskellNixJson; };
pkgs = iohkNix.pkgs;
lib = pkgs.lib;
niv = (import sources.niv {}).niv;
maybeEnv = env: default:
let
result = builtins.getEnv env;
in if result != ""
then result
else default;

pkgs = iohkNix.pkgs;
lib = pkgs.lib;
environments = iohkNix.cardanoLib.environments // {
demo = {
confKey = "dev";
Expand All @@ -36,7 +29,7 @@ let
(name: env: f (env // { inherit name; }))
environments;
in lib // iohkNix.cardanoLib // iohkNix // {
inherit environments forEnvironments;
inherit environments forEnvironments niv iohkNix;
utf8LocaleSetting = ''
export LC_ALL=en_GB.UTF-8
export LANG=en_GB.UTF-8
Expand Down
2 changes: 0 additions & 2 deletions networking/cardano-sl-networking.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ flag benchmarks
Library
exposed-modules: Network.QDisc.Fair

Network.Discovery.Abstract

Network.Broadcast.OutboundQueue
Network.Broadcast.OutboundQueue.Types
Network.Broadcast.OutboundQueue.ConcurrentMultiQueue
Expand Down
31 changes: 0 additions & 31 deletions networking/src/Network/Discovery/Abstract.hs

This file was deleted.

55 changes: 0 additions & 55 deletions networking/src/Network/Discovery/Transport/InMemory.hs

This file was deleted.

1 change: 0 additions & 1 deletion nix/.stack.nix/default.nix

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

53 changes: 0 additions & 53 deletions nix/.stack.nix/network-transport-inmemory.nix

This file was deleted.

4 changes: 2 additions & 2 deletions nix/.stack.nix/network-transport-tcp.nix

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

62 changes: 62 additions & 0 deletions nix/sources.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
{
"gitignore": {
"branch": "master",
"description": "Nix function for filtering local git sources",
"homepage": "",
"owner": "hercules-ci",
"repo": "gitignore",
"rev": "f9e996052b5af4032fe6150bba4a6fe4f7b9d698",
"sha256": "0jrh5ghisaqdd0vldbywags20m2cxpkbbk5jjjmwaw0gr8nhsafv",
"type": "tarball",
"url": "https://github.com/hercules-ci/gitignore/archive/f9e996052b5af4032fe6150bba4a6fe4f7b9d698.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
},
"haskell.nix": {
"branch": "master",
"description": "Alternative Haskell Infrastructure for Nixpkgs",
"homepage": "https://input-output-hk.github.io/haskell.nix",
"owner": "input-output-hk",
"repo": "haskell.nix",
"rev": "3ae2303b14bdebd00437b0e995af2d0eb21abafe",
"sha256": "0dk6541kwfyc5sp5h1vfk6zl4ghln4i2zqkaijbjwv8bnixnm6wl",
"type": "tarball",
"url": "https://github.com/input-output-hk/haskell.nix/archive/3ae2303b14bdebd00437b0e995af2d0eb21abafe.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
},
"iohk-nix": {
"branch": "master",
"description": "nix scripts shared across projects",
"homepage": null,
"owner": "input-output-hk",
"repo": "iohk-nix",
"rev": "f854c957a65295639d2062867552b65c7dc227a6",
"sha256": "1jl07ng2nx6lgj9rrqzl242r263505llzzxb592fn81h0dq6jx1r",
"type": "tarball",
"url": "https://github.com/input-output-hk/iohk-nix/archive/f854c957a65295639d2062867552b65c7dc227a6.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
},
"niv": {
"branch": "iohk",
"description": "Easy dependency management for Nix projects",
"homepage": "https://github.com/nmattia/niv",
"owner": "input-output-hk",
"repo": "niv",
"rev": "c25268460b72cea5b7294354ab019997530a6f3d",
"sha256": "1fgq1nkycm54f431h6wflh6rr7xsq3q2fq9drbgra2fnrsyn65ll",
"type": "tarball",
"url": "https://github.com/input-output-hk/niv/archive/c25268460b72cea5b7294354ab019997530a6f3d.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
},
"nixpkgs": {
"branch": "iohk-19.03",
"description": "Nix Packages collection",
"homepage": null,
"owner": "input-output-hk",
"repo": "nixpkgs",
"rev": "5bd4c4ea6804b54683ef2b802d970ae473e1b658",
"sha256": "12gah6y1lkkgvvdgswyzsqyvxvsvljn61vpy606sy37yfgkc1a63",
"type": "tarball",
"url": "https://github.com/input-output-hk/nixpkgs/archive/5bd4c4ea6804b54683ef2b802d970ae473e1b658.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
}
}
Loading

0 comments on commit 5d0a227

Please sign in to comment.