From 32c05eb5f9b3006e48cd533688cc1e7980e185e3 Mon Sep 17 00:00:00 2001 From: Justin Bedo Date: Wed, 3 Nov 2021 17:57:41 +1100 Subject: update ex-tnpair cluster example - fix bug with deprecated use of slurm tree - remove torque support --- examples/ex-tnpair/README.md | 10 ++-------- examples/ex-tnpair/cluster.nix | 15 ++++++++------- 2 files changed, 10 insertions(+), 15 deletions(-) diff --git a/examples/ex-tnpair/README.md b/examples/ex-tnpair/README.md index 0eef691..54d489a 100644 --- a/examples/ex-tnpair/README.md +++ b/examples/ex-tnpair/README.md @@ -8,15 +8,9 @@ products. Run `nix build -I bionix=../..` in this directory. -# Building via HPC (slurm or torque) +# Building via HPC (slurm) Run `nix build -f cluster.nix` to build on slurm. Note that Nix must be configured such that the temporary build directories are created on -shared storage. - -For Torque, run `nix build -f cluster.nix -I bionix=../.. --argstr -tmpDir /scratch/`. Unlike the slurm handler, a shared tmpdir location -must be specified. - -In both cases, you may need to adjust the resource limits specified in +shared storage. You may need to adjust the resource limits specified in cluster.nix to suit your particular cluster hardware. diff --git a/examples/ex-tnpair/cluster.nix b/examples/ex-tnpair/cluster.nix index 5d4e1de..295d3eb 100644 --- a/examples/ex-tnpair/cluster.nix +++ b/examples/ex-tnpair/cluster.nix @@ -3,13 +3,14 @@ let bionix = import { overlays = [ - (_: super: - super."${if tmpDir == null then "slurm" else "qsub"}" - { - ppn = 24; - mem = 7; - walltime = "3:00:00"; - } // super.lib.optionalAttrs (tmpDir != null) { inherit tmpDir; }) + (_: super: with super; + { + exec = f: def (slurm-exec f) { + ppn = 24; + mem = 7; + walltime = "3:00:00"; + }; + }) (self: super: with super; { -- cgit v1.2.3