Dustin Frisch
1 year ago
No known key found for this signature in database
GPG Key ID: B4C3BF012D9B26BE
5 changed files with 68 additions and 39 deletions
-
6machines/manager/secrets/ldap-sync.conf
-
16machines/manager/users.nix
-
4machines/node/users.nix
-
1shared/default.nix
-
80shared/userenv.nix
@ -1,51 +1,73 @@ |
|||||
{ pkgs, lib, ... }: |
|
||||
|
# 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; |
with lib; |
||||
|
|
||||
let |
let |
||||
userenv = pkgs.buildFHSUserEnv { |
|
||||
|
userenv = pkgs.buildEnv { |
||||
name = "userenv"; |
name = "userenv"; |
||||
targetPkgs = pkgs: with pkgs; [ |
|
||||
git |
|
||||
postgresql |
|
||||
postgresql.lib |
|
||||
papi |
|
||||
gcc |
|
||||
gdb |
|
||||
gnumake |
|
||||
valgrind |
|
||||
|
paths = with pkgs; [ |
||||
autoconf |
autoconf |
||||
automake |
automake |
||||
perl |
|
||||
zlib |
|
||||
python3 |
|
||||
libtool |
|
||||
|
bash |
||||
|
coreutils |
||||
|
curl |
||||
|
fd |
||||
flex |
flex |
||||
pandoc |
|
||||
|
gcc |
||||
|
gdb |
||||
|
git |
||||
|
gnumake |
||||
hwloc |
hwloc |
||||
munge |
|
||||
numactl |
|
||||
libbfd |
libbfd |
||||
libiberty |
libiberty |
||||
|
libtool |
||||
|
munge |
||||
|
nano |
||||
|
numactl |
||||
|
openmpi |
||||
|
openssh |
||||
|
pandoc |
||||
|
papi |
||||
|
perl |
||||
pkgconfig |
pkgconfig |
||||
|
postgresql |
||||
|
postgresql.lib |
||||
|
python3 |
||||
|
ripgrep |
||||
|
tmux |
||||
ucx |
ucx |
||||
openmpi |
|
||||
|
valgrind |
||||
vim |
vim |
||||
nano |
|
||||
wget |
wget |
||||
curl |
|
||||
tmux |
|
||||
fd |
|
||||
ripgrep |
|
||||
bash |
|
||||
|
zlib |
||||
]; |
]; |
||||
|
|
||||
|
ignoreCollisions = false; |
||||
|
|
||||
|
inherit (config.environment) pathsToLink extraOutputsToInstall; |
||||
}; |
}; |
||||
|
|
||||
in |
in |
||||
{ |
{ |
||||
environment.systemPackages = [ userenv ]; |
|
||||
|
# environment.systemPackages = [ userenv ]; |
||||
|
|
||||
# Install userenv to a well-known path |
|
||||
system.systemBuilderCommands = '' |
|
||||
ln -s ${userenv}/bin/userenv $out/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; |
||||
|
}; |
||||
} |
} |
Write
Preview
Loading…
Cancel
Save
Reference in new issue