forked from rarias/jungle
develop: support for srun
This commit is contained in:
parent
f87d830218
commit
df1f22c122
@ -33,10 +33,13 @@ stdenv.mkDerivation {
|
||||
export TEMP=/tmp
|
||||
|
||||
export LANG=en_US.UTF-8
|
||||
export TERM=linux
|
||||
|
||||
source ${stdenv}/setup
|
||||
|
||||
# Access to bin and nix tools for srun, as it keeps the PATH
|
||||
export "PATH=\$PATH:/bin"
|
||||
export "PATH=$PATH:/gpfs/projects/bsc15/nix/bin"
|
||||
|
||||
if [[ -z "\$@" ]]; then
|
||||
exec ${bashInteractive}/bin/bash
|
||||
else
|
||||
|
12
overlay.nix
12
overlay.nix
@ -198,7 +198,7 @@ let
|
||||
];
|
||||
};
|
||||
|
||||
develop = bsc.garlic.stages.exec {
|
||||
develop = bsc.garlic.stages.exec rec {
|
||||
nextStage = bsc.garlic.stages.isolate {
|
||||
nextStage = bsc.garlic.unsafeDevelop;
|
||||
nixPrefix = bsc.garlic.targetMachine.config.nixPrefix;
|
||||
@ -206,9 +206,15 @@ let
|
||||
};
|
||||
nixPrefix = bsc.garlic.targetMachine.config.nixPrefix;
|
||||
# This hack uploads all dependencies to MN4
|
||||
pre = ''
|
||||
pre = let
|
||||
nixPrefix = bsc.garlic.targetMachine.config.nixPrefix;
|
||||
stageProgram = bsc.garlicTools.stageProgram;
|
||||
in
|
||||
''
|
||||
# Hack to upload this to MN4: @upload-to-mn@
|
||||
# Run the following command in a normal interactive shell (outside nix)
|
||||
|
||||
# Create a link to the develop script
|
||||
ln -fs ${nixPrefix}${stageProgram nextStage} .nix-develop
|
||||
'';
|
||||
post = "\n";
|
||||
};
|
||||
|
Loading…
x
Reference in New Issue
Block a user