default.nix 2.23 KB
Newer Older
Valentin Reis's avatar
.  
Valentin Reis committed
1
{
Valentin Reis's avatar
Valentin Reis committed
2
  hostNixpkgs ? <nixpkgs>,
Valentin Reis's avatar
Valentin Reis committed
3
  pkgs         ? import ../pin.nix {
Valentin Reis's avatar
Valentin Reis committed
4
    hostPkgs = import hostNixpkgs {};
Valentin Reis's avatar
Valentin Reis committed
5 6 7
    jsonpath =../nixpkgs-18.03.json;
  },
  datamovepkgs ? import ../pin.nix {
Valentin Reis's avatar
Valentin Reis committed
8
    hostPkgs = import hostNixpkgs {};
Valentin Reis's avatar
Valentin Reis committed
9 10
    jsonpath=../datamove.json;
  },
Valentin Reis's avatar
Valentin Reis committed
11
  packagepins ? import ./pins.nix {inherit (pkgs) stdenv fetchgit fetchgitPrivate;}
Valentin Reis's avatar
.  
Valentin Reis committed
12 13 14
}:
let
  callPackage = pkgs.lib.callPackageWith pkgs;
Valentin Reis's avatar
Valentin Reis committed
15
  pythonPackages = pkgs.python27Packages;
Valentin Reis's avatar
.  
Valentin Reis committed
16 17 18 19
in rec {

    nrm-containers = callPackage ./containers {
      inherit pythonPackages;
Valentin Reis's avatar
Valentin Reis committed
20
      src = packagepins.containers.nix;
Valentin Reis's avatar
.  
Valentin Reis committed
21 22 23 24
    };

    nrm = callPackage ./nrm {
      inherit pythonPackages nrm-containers;
Valentin Reis's avatar
Valentin Reis committed
25
      src = packagepins.nrm.bandit;
Valentin Reis's avatar
.  
Valentin Reis committed
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 59 60 61 62 63 64 65 66 67 68 69 70 71
    };
}
    # not buildable unless results are present(uses sudo: launch expes in nix-shell)
    #appli-enforce = callPackage src/experiments/default.nix
    #{ inherit nrm nrm-containers zymake app target;
      #application= app;
      #samplesize = samplesize-enforce;
      #result_type = "enforce";};

    ## not buildable unless results are present(uses sudo: launch expes in nix-shell)
    #appli-bandit = callPackage src/experiments/default.nix
    #{ inherit nrm nrm-containers zymake app target;
      #application= app;
      #samplesize = samplesize-bandit;
      #result_type = "bandit";};

    #app-analysis-enforce = callPackage src/analysis/default.nix
    #{ inherit zymake;
      #input-enforce=appli-enforce;
      #analysis_type = "enforce";
      #target = "dummy";
    #};

    #app-analysis-bandit = callPackage src/analysis/default.nix
    #{ inherit zymake;
      #analysis_type = "bandit";
      #input-bandit = appli-bandit;
      #input-enforce = appli-enforce;
      #target = "dummy";
    #};

    #dev = let
      #conf = pkgs.writeText "hound.conf" ''
        #{ "max-concurrent-indexers" : 2,
          #"dbpath" : "${builtins.toPath ./.}/hound",
          #"repos" : {
            #"nrm" : { "url" : "file://${builtins.toPath ./nrm}" },
            #"containers" : { "url" : "file://${builtins.toPath ./containers}" } } }
      #'';
    #in pkgs.stdenv.mkDerivation {
      ##not buildable
      #name="nrm-experimental-environment";
      #buildInputs = [nrm pkgs.hound];
      #shellHook = "${pkgs.hound}/bin/houndd -conf ${conf} &";
    #};
    #inherit pkgs;