NixOS configuration for HPC cluster https://docs.hpc.informatik.hs-fulda.de/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

73 lines
1.3 KiB

# This is the environment that we show for the users.
# Hear me out... I already regrett doing this while writing this, but (l)users
# are not willing to pick up the nix-struggle for the greater benefit. So, here
# I am building this shit that I know will fall apart soon.
{ pkgs, lib, config, ... }:
with lib;
let
userenv = pkgs.buildEnv {
name = "userenv";
paths = with pkgs; [
autoconf
automake
bash
coreutils
curl
fd
flex
gcc
gdb
git
gnumake
hwloc
libbfd
libiberty
libtool
munge
nano
numactl
openmpi
openssh
pandoc
papi
perl
pkgconfig
postgresql
postgresql.lib
python3
ripgrep
tmux
ucx
valgrind
vim
wget
zlib
];
ignoreCollisions = false;
inherit (config.environment) pathsToLink extraOutputsToInstall;
};
in
{
# environment.systemPackages = [ userenv ];
environment.extraInit = ''
if [[ "$(id -gn)" -eq "cluster" ]]; then
export PKG_CONFIG_PATH="${makeSearchPath "lib/pkgconfig" config.environment.profiles}"
fi
'';
environment.profiles = [
"/etc/profiles/per-group/$(id -gn)"
];
environment.etc."userenv" = {
target = "profiles/per-group/cluster";
source = userenv;
};
}