{ config, lib, pkgs, ... }: { services.munge = { enable = true; password = "/tmp/munge/key"; }; services.slurm = { server.enable = true; client.enable = true; clusterName = "abbenay"; extraConfig = '' # slurm.conf file generated by configurator.html. # Put this file on all nodes of your cluster. # See the slurm.conf man page for more information. SlurmctldHost=abbenay MpiDefault=none ReturnToService=1 SwitchType=switch/none TaskPlugin=task/affinity SrunPortRange=60001-63000 # TIMERS InactiveLimit=0 KillWait=30 MinJobAge=300 SlurmctldTimeout=120 SlurmdTimeout=300 Waittime=0 # SCHEDULING SchedulerType=sched/backfill SelectType=select/cons_tres # LOGGING AND ACCOUNTING JobAcctGatherFrequency=30 JobAcctGatherType=jobacct_gather/linux AccountingStorageType=accounting_storage/slurmdbd SlurmctldDebug=info SlurmctldLogFile=/var/log/slurmctld.log SlurmdDebug=info SlurmdLogFile=/var/log/slurmd.log # COMPUTE NODES NodeName=abbenay CPUs=4 State=UNKNOWN NodeName=cyberbox CPUs=1 State=UNKNOWN # [add more nodes here] PartitionName=debug Nodes=ALL Default=YES MaxTime=INFINITE State=UP ''; dbdserver = { enable = true; dbdHost = "abbenay"; extraConfig = '' StoragePass=hello StoragePort = ${builtins.toString (builtins.head config.services.mysql.settings.mysqld.port)} ''; }; }; networking.firewall.allowedTCPPorts = [ 6817 6818 6819 ]; networking.firewall.allowedTCPPortRanges = [ { from = 60001; to = 63000; } ]; services.mysql = { enable = true; package = pkgs.mariadb; }; networking.hosts."192.168.69.104" = [ "cyberbox" ]; networking.firewall.enable = false; environment.systemPackages = with pkgs; [ cmake lapack blas netcdf netcdffortran perl libxml2 pkg-config perl534Packages.XMLLibXML tcsh subversion openmpi ]; }